summaryrefslogtreecommitdiff
path: root/tests/typ/compiler/methods.typ
diff options
context:
space:
mode:
authorLaurenz <laurmaedje@gmail.com>2023-01-27 11:54:30 +0100
committerLaurenz <laurmaedje@gmail.com>2023-01-27 11:54:30 +0100
commita8fd64f9289b92614b9e6c16e909ec0c45429027 (patch)
tree76ce8797a6fe9c8b8c0bb1783910ba4b9e22da8b /tests/typ/compiler/methods.typ
parent33585d9a3fbab8a76d3fd8e9c2560f929202a518 (diff)
Hashtags everywhere!
Diffstat (limited to 'tests/typ/compiler/methods.typ')
-rw-r--r--tests/typ/compiler/methods.typ20
1 files changed, 10 insertions, 10 deletions
diff --git a/tests/typ/compiler/methods.typ b/tests/typ/compiler/methods.typ
index f468320b..ae0945df 100644
--- a/tests/typ/compiler/methods.typ
+++ b/tests/typ/compiler/methods.typ
@@ -7,7 +7,7 @@
---
// Test mutating indexed value.
-{
+#{
let matrix = (((1,), (2,)), ((3,), (4,)))
matrix.at(1).at(0).push(5)
test(matrix, (((1,), (2,)), ((3, 5), (4,))))
@@ -15,7 +15,7 @@
---
// Test multiline chain in code block.
-{
+#{
let rewritten = "Hello. This is a sentence. And one more."
.split(".")
.map(s => s.trim())
@@ -27,20 +27,20 @@
}
---
-// Error: 2:3-2:16 type array has no method `fun`
+// Error: 2:4-2:17 type array has no method `fun`
#let numbers = ()
-{ numbers.fun() }
+#{ numbers.fun() }
---
-// Error: 2:3-2:44 cannot mutate a temporary value
+// Error: 2:4-2:45 cannot mutate a temporary value
#let numbers = (1, 2, 3)
-{ numbers.map(v => v / 2).sorted().map(str).remove(4) }
+#{ numbers.map(v => v / 2).sorted().map(str).remove(4) }
---
-// Error: 2:3-2:19 cannot mutate a temporary value
+// Error: 2:4-2:20 cannot mutate a temporary value
#let numbers = (1, 2, 3)
-{ numbers.sorted() = 1 }
+#{ numbers.sorted() = 1 }
---
-// Error: 3-6 cannot mutate a constant
-{ box.push(1) }
+// Error: 4-7 cannot mutate a constant
+#{ box.push(1) }