diff options
Diffstat (limited to 'npc/dev/test.txt')
-rw-r--r-- | npc/dev/test.txt | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/npc/dev/test.txt b/npc/dev/test.txt index b711a0a28..b35beb8ed 100644 --- a/npc/dev/test.txt +++ b/npc/dev/test.txt @@ -268,6 +268,19 @@ function script HerculesSelfTestHelper { callsub(OnCheck, "Order of + and *", .@x, 7); + // Binary ** operator + .@x = 2 ** 3; // .@x = 8; + callsub(OnCheck, "Binary ** operator", .@x, 8); + + // Associativity of ** + .@x = 2 ** 3 ** 2; // .@x = (2 ** 3) ** 2; + callsub(OnCheck, "Associativity of **", .@x, 64); + + // Order of ** and * + .@x = 5 * 2 ** 3 * 2; // .@x = 5 * (2 ** 3) * 2; + callsub(OnCheck, "Order of ** and *", .@x, 80); + + // << and >> operators .@x = 1<<3; // .@x = 1*2*2*2; callsub(OnCheck, "Left shift << operator", .@x, 8); |