✨
This commit is contained in:
@ -1,4 +1,4 @@
|
||||
hello|
|
||||
$2 -> x|
|
||||
set 2 -> x|
|
||||
do print<variable x;>|
|
||||
goodbye|
|
@ -1,10 +1,10 @@
|
||||
hello|
|
||||
$1 -> x|
|
||||
$2 -> y|
|
||||
$5 -> z|
|
||||
$variable x+variable y -> z| // 3
|
||||
$5-variable z -> z| // 2
|
||||
$2*variable z -> x| // 4
|
||||
$variable x/variable y -> y| // 2
|
||||
set 1 -> x|
|
||||
set 2 -> y|
|
||||
set 5 -> z|
|
||||
set variable x+variable y -> z| // 3
|
||||
set 5-variable z -> z| // 2
|
||||
set 2*variable z -> x| // 4
|
||||
set variable x/variable y -> y| // 2
|
||||
do print<variable x;variable y;variable z;>|
|
||||
goodbye|
|
@ -1,6 +1,6 @@
|
||||
hello|
|
||||
[
|
||||
$5 -> x|
|
||||
set 5 -> x|
|
||||
do print<variable x;>|
|
||||
]|
|
||||
goodbye|
|
@ -1,5 +1,5 @@
|
||||
hello|
|
||||
$1 -> x|
|
||||
maybe $variable x + 1 -> x|
|
||||
set 1 -> x|
|
||||
maybe set variable x + 1 -> x|
|
||||
do print<variable x;>|
|
||||
goodbye|
|
@ -1,5 +1,5 @@
|
||||
hello|
|
||||
$2 -> x|
|
||||
set 2 -> x|
|
||||
do print<'a';> if variable x = 1|
|
||||
do print<'b';> if variable x = 2|
|
||||
goodbye|
|
@ -1,8 +1,8 @@
|
||||
hello|
|
||||
$ 1 + 2 * 3 -> x|
|
||||
set 1 + 2 * 3 -> x|
|
||||
do print<variable x;>|
|
||||
$ 5 -> y if variable x = 7|
|
||||
set 5 -> y if variable x = 7|
|
||||
do print<variable y;>|
|
||||
$$5 -> z + 1 -> a|
|
||||
set set 5 -> z + 1 -> a|
|
||||
do print<variable z; variable a;>|
|
||||
goodbye|
|
@ -1,2 +1,2 @@
|
||||
$2 -> x|
|
||||
set 2 -> x|
|
||||
goodbye|
|
@ -1,2 +1,2 @@
|
||||
hello|
|
||||
$2 -> x|
|
||||
set 2 -> x|
|
@ -1,6 +1,6 @@
|
||||
hello|
|
||||
${1;2;3;} -> x|
|
||||
set {1;2;3;} -> x|
|
||||
do print<variable x;>|
|
||||
${1;1+1;do print<3;>;} -> y|
|
||||
set {1;1+1;do print<3;>;} -> y|
|
||||
do print<variable y{5 - 4};>|
|
||||
goodbye|
|
1
tests/13_because.expected
Normal file
1
tests/13_because.expected
Normal file
@ -0,0 +1 @@
|
||||
3
|
5
tests/13_because.plthy
Normal file
5
tests/13_because.plthy
Normal file
@ -0,0 +1,5 @@
|
||||
hello|
|
||||
set 2 -> x|
|
||||
set 3 -> x because variable x = 2|
|
||||
do print<variable x;>|
|
||||
goodbye|
|
1
tests/14_E005-random.expected
Normal file
1
tests/14_E005-random.expected
Normal file
@ -0,0 +1 @@
|
||||
E005: Wrong number of arguments for builtin 'random' (1) at line 2
|
3
tests/14_E005-random.plthy
Normal file
3
tests/14_E005-random.plthy
Normal file
@ -0,0 +1,3 @@
|
||||
hello|
|
||||
do random<2;>|
|
||||
goodbye|
|
1
tests/15_C001.expected
Normal file
1
tests/15_C001.expected
Normal file
@ -0,0 +1 @@
|
||||
C001: Because assertion incorrect
|
5
tests/15_C001.plthy
Normal file
5
tests/15_C001.plthy
Normal file
@ -0,0 +1,5 @@
|
||||
hello|
|
||||
set 2 -> x|
|
||||
set 3 -> x because variable x = 3|
|
||||
do print<variable x;>|
|
||||
goodbye|
|
Reference in New Issue
Block a user