Changeset: f30e5a946488 for MonetDB URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=f30e5a946488 Added Files: monetdb5/modules/atoms/Tests/json00.mal monetdb5/modules/atoms/Tests/json00.stable.err monetdb5/modules/atoms/Tests/json00.stable.out monetdb5/modules/atoms/Tests/json01.mal monetdb5/modules/atoms/Tests/json01.stable.err monetdb5/modules/atoms/Tests/json01.stable.out monetdb5/modules/atoms/Tests/json02.mal monetdb5/modules/atoms/Tests/json02.stable.err monetdb5/modules/atoms/Tests/json02.stable.out monetdb5/modules/atoms/Tests/json03.mal monetdb5/modules/atoms/Tests/json03.stable.err monetdb5/modules/atoms/Tests/json03.stable.out monetdb5/modules/atoms/Tests/jsonrender.mal monetdb5/modules/atoms/Tests/jsonrender.stable.err monetdb5/modules/atoms/Tests/jsonrender.stable.out monetdb5/modules/atoms/json_atom.c monetdb5/modules/atoms/json_atom.h monetdb5/modules/atoms/json_atom.mal sql/scripts/40_json.sql sql/test/BugTracker-2013/Tests/add_boolean.Bug-3289.sql sql/test/BugTracker-2013/Tests/add_boolean.Bug-3289.stable.err sql/test/BugTracker-2013/Tests/add_boolean.Bug-3289.stable.out sql/test/Tests/table_function.sql.src sql/test/json/Tests/miniexample.sql sql/test/json/Tests/parsing.sql sql/test/json/Tests/parsing.stable.err sql/test/json/Tests/parsing.stable.out sql/test/table_function.sql Modified Files: NT/rules.msc gdk/gdk_aggr.c gdk/gdk_join.c gdk/gdk_search.c gdk/gdk_select.c java/ChangeLog.Feb2013 java/Makefile.ag java/build.properties java/pom.xml java/release.txt java/src/nl/cwi/monetdb/jdbc/MonetPreparedStatement.java java/tests/Test_PStypes.java monetdb5/extras/jaql/parser/Makefile.ag monetdb5/mal/mal_interpreter.c monetdb5/mal/mal_interpreter.h monetdb5/mal/mal_parser.c monetdb5/mal/mal_profiler.c monetdb5/mal/mal_profiler.h monetdb5/mal/mal_runtime.c monetdb5/modules/atoms/Makefile.ag monetdb5/modules/atoms/Tests/All monetdb5/modules/mal/mal_init.mal monetdb5/modules/mal/profiler.c monetdb5/modules/mal/profiler.h monetdb5/modules/mal/profiler.mal monetdb5/modules/mal/sysmon.c monetdb5/optimizer/opt_centipede.c monetdb5/optimizer/opt_querylog.c monetdb5/optimizer/optimizer.mal sql/backends/monet5/rel_bin.c sql/backends/monet5/sql.mx sql/backends/monet5/sql_result.c sql/server/rel_planner.c sql/server/rel_select.c sql/storage/bat/bat_storage.c sql/test/BugTracker-2013/Tests/All sql/test/Tests/All Branch: rdf Log Message:
Merge with default branch diffs (truncated from 4431 to 300 lines): diff --git a/NT/rules.msc b/NT/rules.msc --- a/NT/rules.msc +++ b/NT/rules.msc @@ -58,6 +58,10 @@ DEBUGLIB= # warnings about casts which results in the code being uncompilable W_CFLAGS = !ENDIF +!IFDEF ENABLE_STRICT +# strict mode: treat warnings as errors +W_CFLAGS = -WX +!ENDIF # This is the location of pthreads for Win32, # see http://sources.redhat.com/pthreads-win32/ @@ -198,10 +202,10 @@ CONFIGURE_PY = "$(TOPDIR)\..\NT\winconfi WINCONFIG_INCS = "-I$(TOPDIR)\..\buildtools\conf" !IFDEF DEBUG -COMPILERFLAGS = -GF -W3 $(W_CFLAGS) -wd4273 -wd4102 -MDd -nologo -Od -D_DEBUG -RTC1 -Zi +COMPILERFLAGS = -GF -W3 $(W_CFLAGS) -MDd -nologo -Od -D_DEBUG -RTC1 -Zi !ELSE # add -Zi flag (implies -debug, not -D_DEBUG) to get symbol info in .pdb files -COMPILERFLAGS = -GF -W3 $(W_CFLAGS) -wd4273 -wd4102 -MD -nologo -Ox -Zi +COMPILERFLAGS = -GF -W3 $(W_CFLAGS) -MD -nologo -Ox -Zi !ENDIF CFLAGS = $(COMPILERFLAGS) -I. -I$(TOPDIR) $(LIBC_INCS) $(INCLUDES) $(WINCONFIG_INCS) $(ICONV_CFLAGS) diff --git a/gdk/gdk_aggr.c b/gdk/gdk_aggr.c --- a/gdk/gdk_aggr.c +++ b/gdk/gdk_aggr.c @@ -1060,7 +1060,7 @@ BATprod(void *res, int tp, BAT *b, BAT * /* loop invariant: */ \ /* (x - a) - z1 * n == z2 */ \ while (z2 >= (BUN) (n)) { \ - z2 -= (n); \ + z2 -= (BUN) (n); \ z1++; \ } \ } else { \ @@ -1071,10 +1071,10 @@ BATprod(void *res, int tp, BAT *b, BAT * z1--; \ if (z2 < (BUN) (n)) { \ /* proper remainder */ \ - z2 = (n) - z2; \ + z2 = (BUN) ((n) - z2); \ break; \ } \ - z2 -= (n); \ + z2 -= (BUN) (n); \ } \ } \ (a) += z1; \ diff --git a/gdk/gdk_join.c b/gdk/gdk_join.c --- a/gdk/gdk_join.c +++ b/gdk/gdk_join.c @@ -353,7 +353,7 @@ mergejoin(BAT *r1, BAT *r2, BAT *l, BAT if (l->ttype == TYPE_void) { if (lcand) { lstart = 0; - lend = lcandend - lcand; + lend = (BUN) (lcandend - lcand); lvals = (const char *) lcand; lcand = NULL; lwidth = SIZEOF_OID; @@ -366,7 +366,7 @@ mergejoin(BAT *r1, BAT *r2, BAT *l, BAT if (r->ttype == TYPE_void) { if (rcand) { rstart = 0; - rend = rcandend - rcand; + rend = (BUN) (rcandend - rcand); rvals = (const char *) rcand; rcand = NULL; rwidth = SIZEOF_OID; @@ -407,7 +407,7 @@ mergejoin(BAT *r1, BAT *r2, BAT *l, BAT rval = oid_nil; v = (const char *) &rval; } else if (roff != 0) { - rval = *(const oid *)v + roff; + rval = (oid) (*(const oid *)v + roff); v = (const char *) &rval; } } else { @@ -427,7 +427,7 @@ mergejoin(BAT *r1, BAT *r2, BAT *l, BAT lcand += binsearch(lcand, l->hseqbase, lvals, lvars, lwidth, lscan, - lcandend - lcand, v, + (BUN) (lcandend - lcand), v, cmp, lordering, 0); if (lcand == lcandend) break; @@ -492,7 +492,7 @@ mergejoin(BAT *r1, BAT *r2, BAT *l, BAT cmp(v, VALUE(l, lcand[lscan] - l->hseqbase)) == 0) { /* lots of equal values: use binary * search to find end */ - nl = binsearch(lcand, l->hseqbase, lvals, lvars, lwidth, lscan, lcandend - lcand, v, cmp, lordering, 1); + nl = binsearch(lcand, l->hseqbase, lvals, lvars, lwidth, lscan, (BUN) (lcandend - lcand), v, cmp, lordering, 1); lcand += nl; } else { while (++lcand < lcandend && @@ -528,7 +528,7 @@ mergejoin(BAT *r1, BAT *r2, BAT *l, BAT } /* now fix offset */ if (loff != 0) { - lval = *(const oid *)v + loff; + lval = (oid) (*(const oid *)v + loff); v = (const char *) &lval; } } @@ -585,7 +585,7 @@ mergejoin(BAT *r1, BAT *r2, BAT *l, BAT rcand += binsearch(rcand, r->hseqbase, rvals, rvars, rwidth, rscan, - rcandend - rcand, v, + (BUN) (rcandend - rcand), v, cmp, rordering, 0); } else { /* scan r for v */ @@ -602,7 +602,7 @@ mergejoin(BAT *r1, BAT *r2, BAT *l, BAT * search */ nr = binsearch(rcand, r->hseqbase, rvals, rvars, rwidth, - rscan, rcandend - rcand, + rscan, (BUN) (rcandend - rcand), v, cmp, rordering, 1); rcand += nr; } else { @@ -699,7 +699,7 @@ mergejoin(BAT *r1, BAT *r2, BAT *l, BAT * see whether we're better off doing * a binary search */ if (rscan < (BUN) (rcandend - rcand) && - rordering * cmp(v, VALUE(r, rcandend[-rscan - 1] - r->hseqbase)) < 0) { + rordering * cmp(v, VALUE(r, rcandend[-(ssize_t)rscan - 1] - r->hseqbase)) < 0) { /* value too far away in r: * use binary search */ rcandend = rcand + binsearch(rcand, @@ -721,7 +721,7 @@ mergejoin(BAT *r1, BAT *r2, BAT *l, BAT * see whether we're better off doing * a binary search */ if (rscan < (BUN) (rcandend - rcand) && - cmp(v, VALUE(r, rcandend[-rscan - 1] - r->hseqbase)) == 0) { + cmp(v, VALUE(r, rcandend[-(ssize_t)rscan - 1] - r->hseqbase)) == 0) { nr = binsearch(rcand, r->hseqbase, rvals, rvars, rwidth, 0, (BUN) (rcandend - rcand) - rscan, @@ -1143,7 +1143,7 @@ hashjoin(BAT *r1, BAT *r2, BAT *l, BAT * nr = 0; if (rcand) { HASHloop(ri, r->H->hash, rb, v) { - ro = (oid) rb + rbun2oid; + ro = (oid) (rb + rbun2oid); if (!binsearchcand(rcand, 0, nrcand, ro)) continue; if (BUNlast(r1) == BATcapacity(r1)) { @@ -1177,7 +1177,7 @@ hashjoin(BAT *r1, BAT *r2, BAT *l, BAT * goto bailout; assert(BATcapacity(r1) == BATcapacity(r2)); } - ro = (oid) rb + rbun2oid; + ro = (oid) (rb + rbun2oid); APPEND(r1, lo); APPEND(r2, ro); nr++; @@ -1242,7 +1242,7 @@ hashjoin(BAT *r1, BAT *r2, BAT *l, BAT * nr = 0; if (rcand) { HASHloop(ri, r->H->hash, rb, v) { - ro = (oid) rb + rbun2oid; + ro = (oid) (rb + rbun2oid); if (!binsearchcand(rcand, 0, nrcand, ro)) continue; if (BUNlast(r1) == BATcapacity(r1)) { @@ -1276,7 +1276,7 @@ hashjoin(BAT *r1, BAT *r2, BAT *l, BAT * goto bailout; assert(BATcapacity(r1) == BATcapacity(r2)); } - ro = (oid) rb + rbun2oid; + ro = (oid) (rb + rbun2oid); APPEND(r1, lo); APPEND(r2, ro); nr++; @@ -1472,7 +1472,7 @@ thetajoin(BAT *r1, BAT *r2, BAT *l, BAT } if (lcand) { lstart = 0; - lend = lcandend - lcand; + lend = (BUN) (lcandend - lcand); lvals = (const char *) lcand; lcand = NULL; lwidth = SIZEOF_OID; @@ -1486,7 +1486,7 @@ thetajoin(BAT *r1, BAT *r2, BAT *l, BAT } if (rcand) { rstart = 0; - rend = rcandend - rcand; + rend = (BUN) (rcandend - rcand); rvals = (const char *) rcand; rcand = NULL; rwidth = SIZEOF_OID; @@ -1516,7 +1516,7 @@ thetajoin(BAT *r1, BAT *r2, BAT *l, BAT if (lvals) { vl = VALUE(l, lstart); if (loff != 0) { - lval = *(const oid *)vl + loff; + lval = (oid) (*(const oid *)vl + loff); vl = (const char *) &lval; } } else { @@ -1542,7 +1542,7 @@ thetajoin(BAT *r1, BAT *r2, BAT *l, BAT if (rvals) { vr = VALUE(r, n); if (roff != 0) { - rval = *(const oid *)vr + roff; + rval = (oid) (*(const oid *)vr + roff); vr = (const char *) &rval; } } else { diff --git a/gdk/gdk_search.c b/gdk/gdk_search.c --- a/gdk/gdk_search.c +++ b/gdk/gdk_search.c @@ -222,7 +222,7 @@ BAT * BAThash(BAT *b, BUN masksize) { BAT *o = NULL; - lng t0,t1; + lng t0 = 0, t1 = 0; (void) t0; (void) t1; diff --git a/gdk/gdk_select.c b/gdk/gdk_select.c --- a/gdk/gdk_select.c +++ b/gdk/gdk_select.c @@ -144,7 +144,7 @@ BAT_hashselect(BAT *b, BAT *s, BAT *bn, assert(s->tsorted); s = BATmirror(s); /* SORTfnd works on HEAD column */ HASHloop(bi, b->H->hash, i, tl) { - o = (oid) i + off; + o = (oid) (i + off); if (SORTfnd(s, &o) != BUN_NONE) { buninsfix(bn, T, dst, cnt, oid, o, maximum - BATcapacity(bn), @@ -154,7 +154,7 @@ BAT_hashselect(BAT *b, BAT *s, BAT *bn, } } else { HASHloop(bi, b->H->hash, i, tl) { - o = (oid) i + off; + o = (oid) (i + off); buninsfix(bn, T, dst, cnt, oid, o, maximum - BATcapacity(bn), maximum, NULL); @@ -279,12 +279,12 @@ do { \ \ if (BATcapacity(bn) < maximum) { \ impsloop(CAND, TEST, \ - buninsfix(bn, T, dst, cnt, oid, o + off, \ + buninsfix(bn, T, dst, cnt, oid, (oid)(o + off), \ (BUN) ((dbl) cnt / (dbl) (p-r) \ * (dbl) (q-p) * 1.1 + 1024), \ BATcapacity(bn) + q - p, BUN_NONE)); \ } else { \ - impsloop(CAND, TEST, dst[cnt] = o + off); \ + impsloop(CAND, TEST, dst[cnt] = (oid)(o + off)); \ } \ } while (0) @@ -318,7 +318,7 @@ do { \ while (p < q) { \ CAND; \ v = src[o]; \ - buninsfix(bn, T, dst, cnt, oid, o + off, \ + buninsfix(bn, T, dst, cnt, oid, (oid)(o + off), \ (BUN) ((dbl) cnt / (dbl) (p-r) \ * (dbl) (q-p) * 1.1 + 1024), \ BATcapacity(bn) + q - p, BUN_NONE); \ @@ -329,7 +329,7 @@ do { \ while (p < q) { \ CAND; \ v = src[o]; \ - dst[cnt] = o + off; \ + dst[cnt] = (oid)(o + off); \ cnt += (TEST); \ p++; \ } \ @@ -407,8 +407,8 @@ NAME##_##TYPE (BAT *b, BAT *s, BAT *bn, if (use_imprints && VIEWtparent(b)) { \ BAT *parent = BATmirror(BATdescriptor(VIEWtparent(b))); \ imprints = parent->T->imprints; \ - pr_off = (TYPE *)Tloc(b,0) - \ - (TYPE *)Tloc(parent,0)+BUNfirst(parent); \ + pr_off = (BUN) ((TYPE *)Tloc(b,0) - \ + (TYPE *)Tloc(parent,0)+BUNfirst(parent)); \ BBPunfix(parent->batCacheid); \ } else { \ imprints= b->T->imprints; \ @@ -455,7 +455,7 @@ candscan_any (BAT *b, BAT *s, BAT *bn, c BATgetId(s), anti); while (p < q) { o = *candlist++; - v = BUNtail(bi,o-off); + v = BUNtail(bi,(BUN)(o-off)); _______________________________________________ checkin-list mailing list checkin-list@monetdb.org http://mail.monetdb.org/mailman/listinfo/checkin-list