summaryrefslogtreecommitdiff
path: root/tests/typ/expr/prec.typ
diff options
context:
space:
mode:
authorLaurenz <laurmaedje@gmail.com>2021-05-18 00:36:11 +0200
committerLaurenz <laurmaedje@gmail.com>2021-05-18 00:36:11 +0200
commit8b58171d7ca036d71b32749286c251cc91bdd10e (patch)
tree4594ab5088edf8eec44f3bafe3fb8fecb13ac61b /tests/typ/expr/prec.typ
parent8d67c0ca5eb3486dde97fd281bd4a51d535c600c (diff)
Reorganize test cases
Diffstat (limited to 'tests/typ/expr/prec.typ')
-rw-r--r--tests/typ/expr/prec.typ30
1 files changed, 0 insertions, 30 deletions
diff --git a/tests/typ/expr/prec.typ b/tests/typ/expr/prec.typ
deleted file mode 100644
index e64e583c..00000000
--- a/tests/typ/expr/prec.typ
+++ /dev/null
@@ -1,30 +0,0 @@
-// Test operator precedence.
-// Ref: false
-
----
-// Multiplication binds stronger than addition.
-#test(1+2*-3, -5)
-
-// Subtraction binds stronger than comparison.
-#test(3 == 5 - 2, true)
-
-// Boolean operations bind stronger than '=='.
-#test("a" == "a" and 2 < 3, true)
-#test(not "b" == "b", false)
-
-// Assignment binds stronger than boolean operations.
-// Error: 2-7 cannot assign to this expression
-{not x = "a"}
-
----
-// Parentheses override precedence.
-#test((1), 1)
-#test((1+2)*-3, -9)
-
-// Error: 14 expected closing paren
-#test({(1 + 1}, 2)
-
----
-// Precedence doesn't matter for chained unary operators.
-// Error: 2-11 cannot apply '-' to boolean
-{-not true}