Changeset: a48b64db228e for MonetDB
URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=a48b64db228e
Modified Files:
gdk/gdk_setop.mx
Branch: Feb2013
Log Message:
Use C preprocessor instead of constant expression in if statement.
diffs (41 lines):
diff --git a/gdk/gdk_setop.mx b/gdk/gdk_setop.mx
--- a/gdk/gdk_setop.mx
+++ b/gdk/gdk_setop.mx
@@ -72,12 +72,12 @@ All Rights Reserved.
#include "gdk_private.h"
#include "gdk_search.h"
-#define HITk(t1,t2) TRUE
-#define HITs(t1,t2) ((*cmp)(t1,t2) == 0)
-#define EQUALs(t1,t2) ((*cmp)(t1,t2) == 0 && (*cmp)(t1,tnil))
-#define EQUALk(t1,t2) TRUE
-#define FLIPs(l,r) TRUE
-#define FLIPk(l,r) FALSE
+#define HITk(t1,t2) TRUE
+#define HITs(t1,t2) ((*cmp)(t1,t2) == 0)
+#define EQUALs(t1,t2) ((*cmp)(t1,t2) == 0 && (*cmp)(t1,tnil))
+#define EQUALk(t1,t2) TRUE
+#define FLIPs TRUE
+#define FLIPk FALSE
#define HITintersect(h,t) bunfastins(bn,h,t)
#define HITdiff(h,t)
@@ -622,7 +622,9 @@ BATins_@1@2(BAT *bn, BAT *l, BAT *r)
/* determine how to do the intersect */
if (BAThordered(l) & BAThordered(r)) {
hash = FALSE;
- } else if (FLIP@1(l, r)) {
+ }
+#if FLIP@1
+ else {
int flip = BATtordered(l) & BATtordered(r);
if (flip) {
@@ -636,6 +638,7 @@ BATins_@1@2(BAT *bn, BAT *l, BAT *r)
bn = BATmirror(bn);
}
}
+#endif
merge = BATatoms[l->htype].atomCmp;
cmp = BATatoms[l->ttype].atomCmp;
hnil = ATOMnilptr(l->htype);
_______________________________________________
checkin-list mailing list
[email protected]
http://mail.monetdb.org/mailman/listinfo/checkin-list