mirror of
https://github.com/Reuh/anselme.git
synced 2025-10-27 08:39:30 +00:00
Fourth test batch
This commit is contained in:
parent
d928ff5598
commit
0a835a65d8
8 changed files with 65 additions and 0 deletions
5
test/results/closure access upvalue.ans
Normal file
5
test/results/closure access upvalue.ans
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
--# run #--
|
||||
--- return ---
|
||||
"dramatic explosion"
|
||||
--# saved #--
|
||||
{}
|
||||
11
test/results/closure define nested.ans
Normal file
11
test/results/closure define nested.ans
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
--# run #--
|
||||
--- text ---
|
||||
| {}"" {}"42" {}"" |
|
||||
--- error ---
|
||||
[0m[31m[0m[31m[0m[31m[0m[31mno variable "y" defined in closure[0m
|
||||
↳ from [4mtest/tests/closure define nested.ans:12:4[0m in call: [2mf . "y"[0m[0m
|
||||
↳ from [4mtest/tests/closure define nested.ans:12:1[0m in text interpolation: [2m| {f . "y"} |[0m[0m
|
||||
↳ from [4mtest/tests/closure define nested.ans:12:1[0m in translatable: [2m| {f . "y"} |[0m[0m
|
||||
↳ from [4m?[0m in block: [2m:f = ($() _)…[0m
|
||||
--# saved #--
|
||||
{}
|
||||
5
test/results/closure define.ans
Normal file
5
test/results/closure define.ans
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
--# run #--
|
||||
--- return ---
|
||||
"ok"
|
||||
--# saved #--
|
||||
{}
|
||||
11
test/results/index identifier.ans
Normal file
11
test/results/index identifier.ans
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
--# run #--
|
||||
--- text ---
|
||||
| {}"" {}"42" {}"" |
|
||||
--- text ---
|
||||
| {}"" {}"42" {}"" |
|
||||
--- text ---
|
||||
| {}"" {}"42" {}"" |
|
||||
--- return ---
|
||||
()
|
||||
--# saved #--
|
||||
{}
|
||||
7
test/tests/closure access upvalue.ans
Normal file
7
test/tests/closure access upvalue.ans
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
:f = ()
|
||||
_
|
||||
:action = "dramatic explosion"
|
||||
f = $
|
||||
1 + 1
|
||||
|
||||
f.action
|
||||
12
test/tests/closure define nested.ans
Normal file
12
test/tests/closure define nested.ans
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
:f = $
|
||||
| kk
|
||||
:y = $
|
||||
()
|
||||
y.:z = 12
|
||||
| ko
|
||||
|
||||
f.:x = 42
|
||||
|
||||
|{f.x}
|
||||
|
||||
|{f.y}
|
||||
5
test/tests/closure define.ans
Normal file
5
test/tests/closure define.ans
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
:f = $
|
||||
()
|
||||
f.:x = "ok"
|
||||
|
||||
f.x
|
||||
9
test/tests/index identifier.ans
Normal file
9
test/tests/index identifier.ans
Normal file
|
|
@ -0,0 +1,9 @@
|
|||
:f = $()()
|
||||
f.:x = 42
|
||||
|
||||
|{f.x}
|
||||
|
||||
|{(f).x}
|
||||
|
||||
:z = "x"
|
||||
|{(f).(z)}
|
||||
Loading…
Add table
Add a link
Reference in a new issue