aboutsummaryrefslogtreecommitdiffstats
path: root/src/junit/com/jogamp/gluegen/test
diff options
context:
space:
mode:
Diffstat (limited to 'src/junit/com/jogamp/gluegen/test')
-rw-r--r--src/junit/com/jogamp/gluegen/test/junit/generation/BaseClass.java9
-rw-r--r--src/junit/com/jogamp/gluegen/test/junit/generation/test1.h8
2 files changed, 17 insertions, 0 deletions
diff --git a/src/junit/com/jogamp/gluegen/test/junit/generation/BaseClass.java b/src/junit/com/jogamp/gluegen/test/junit/generation/BaseClass.java
index ed23f54..d87053f 100644
--- a/src/junit/com/jogamp/gluegen/test/junit/generation/BaseClass.java
+++ b/src/junit/com/jogamp/gluegen/test/junit/generation/BaseClass.java
@@ -246,6 +246,15 @@ public class BaseClass extends SingletonJunitCase {
Assert.assertEquals( 9, Bindingtest1.NUMBER_NINE);
Assert.assertEquals( 10, Bindingtest1.NUMBER_TEN);
+ // Bitwise not Expression
+ Assert.assertEquals(~ Bindingtest1.NUMBER_ONE, Bindingtest1.BITWISE_NOT_OF_ONE);
+ Assert.assertEquals(~ Bindingtest1.NUMBER_TWO, Bindingtest1.BITWISE_NOT_OF_TWO);
+ Assert.assertEquals(~ Bindingtest1.NUMBER_FOUR, Bindingtest1.BITWISE_NOT_OF_FOUR);
+ Assert.assertEquals(~ Bindingtest1.NUMBER_FIVE, Bindingtest1.BITWISE_NOT_OF_FIVE);
+ Assert.assertEquals(~ Bindingtest1.NUMBER_EIGHT, Bindingtest1.BITWISE_NOT_OF_EIGHT);
+ Assert.assertEquals(~ Bindingtest1.NUMBER_NINE, Bindingtest1.BITWISE_NOT_OF_NINE);
+ Assert.assertEquals(~ Bindingtest1.NUMBER_TEN, Bindingtest1.BITWISE_NOT_OF_TEN);
+
// Enum Constant Expressions!
Assert.assertEquals( 1, Bindingtest1.ENUM_NUM_ONE);
Assert.assertEquals( 2, Bindingtest1.ENUM_NUM_TWO);
diff --git a/src/junit/com/jogamp/gluegen/test/junit/generation/test1.h b/src/junit/com/jogamp/gluegen/test/junit/generation/test1.h
index 89848d7..6e1f8db 100644
--- a/src/junit/com/jogamp/gluegen/test/junit/generation/test1.h
+++ b/src/junit/com/jogamp/gluegen/test/junit/generation/test1.h
@@ -114,6 +114,14 @@ enum CL_INT { ENUM_I0=10, ENUM_I1, ENUM_I2=+12U, ENUM_I3=0x0d, ENUM_I4=-14, ENUM
#define NUMBER_NINE ( 2 * 2 + ( 1 << 2 ) + 1 )
#define NUMBER_TEN ( NUMBER_EIGHT | NUMBER_TWO )
+#define BITWISE_NOT_OF_ONE ~ NUMBER_ONE
+#define BITWISE_NOT_OF_TWO ~ NUMBER_TWO
+#define BITWISE_NOT_OF_FOUR ~ NUMBER_FOUR
+#define BITWISE_NOT_OF_FIVE ~ NUMBER_FIVE
+#define BITWISE_NOT_OF_EIGHT ~ NUMBER_EIGHT
+#define BITWISE_NOT_OF_NINE ~ NUMBER_NINE
+#define BITWISE_NOT_OF_TEN ~ NUMBER_TEN
+
enum NumberOps { ENUM_NUM_ONE = CONSTANT_ONE,
ENUM_NUM_TWO = 1+1,
ENUM_NUM_THREE,