From d42b900388d7a06b1e2eeb93e77a7b7ab95be24f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=89tienne=20Reuh=20Fildadut?= Date: Fri, 29 Dec 2023 19:19:15 +0100 Subject: [PATCH] Text litteral: strip leading and closing space if present --- anselme/ast/Text.lua | 2 +- anselme/ast/TextInterpolation.lua | 2 +- anselme/parser/expression/primary/text.lua | 4 ++ test/results/binary operator overload.ans | 6 +- test/results/binop assignement.ans | 4 +- test/results/choice block.ans | 12 ++-- test/results/choice function.ans | 10 ++-- ...e line interpolation with choice event.ans | 8 +-- ...ce line interpolation with event flush.ans | 8 +-- ...ice line interpolation with text event.ans | 16 ++--- test/results/choice preserve tags.ans | 16 ++--- test/results/choice simple.ans | 6 +- test/results/choice with decorators.ans | 32 +++++----- test/results/closure.ans | 8 +-- test/results/condition decorator.ans | 4 +- test/results/condition else false.ans | 2 +- test/results/condition else true.ans | 2 +- test/results/condition elseif false.ans | 2 +- test/results/condition elseif true.ans | 2 +- test/results/condition operator.ans | 4 +- test/results/condition true.ans | 2 +- test/results/constant variable list.ans | 4 +- .../constrained variable assignement.ans | 4 +- .../constrained variable definition.ans | 4 +- test/results/custom text formatting.ans | 2 +- test/results/equality operator.ans | 22 +++---- test/results/flush.ans | 8 +-- test/results/function arg.ans | 2 +- test/results/function args.ans | 2 +- test/results/function assignement.ans | 10 ++-- test/results/function definition.ans | 10 ++-- test/results/function exported.ans | 16 ++--- test/results/function name dispatch.ans | 4 +- .../function return exit function nested.ans | 4 +- .../results/function return exit function.ans | 2 +- test/results/function return nested.ans | 4 +- test/results/function return.ans | 2 +- test/results/function scope wrong.ans | 4 +- test/results/function scope.ans | 2 +- test/results/function scoped mutable.ans | 60 +++++++++---------- test/results/function scoped nested.ans | 56 ++++++++--------- test/results/function scoped recursive.ans | 28 ++++----- test/results/function scoped.ans | 16 ++--- test/results/function selection.ans | 4 +- ...nction separate variable from variants.ans | 4 +- .../function type dispatch with default.ans | 22 +++---- test/results/function type dispatch.ans | 4 +- test/results/function ufcs arg.ans | 4 +- test/results/function ufcs args.ans | 2 +- test/results/function.ans | 4 +- test/results/implicit multiplication.ans | 10 ++-- test/results/lazy boolean operators.ans | 40 ++++++------- test/results/list assignement.ans | 10 ++-- test/results/list index.ans | 12 ++-- test/results/loop decorator.ans | 22 +++---- test/results/map assignement.ans | 18 +++--- test/results/map index.ans | 6 +- test/results/named arguments.ans | 2 +- ...amespace operator arbitrary expression.ans | 2 +- test/results/nested conditions.ans | 6 +- test/results/nested flush.ans | 16 ++--- test/results/optional arguments.ans | 2 +- test/results/pair operator.ans | 4 +- test/results/persist.ans | 8 +-- test/results/resume anchors.ans | 48 +++++++-------- test/results/return children.ans | 4 +- test/results/return in choice.ans | 6 +- test/results/string escaping.ans | 8 +-- test/results/symbol alias.ans | 8 +-- test/results/tag decorator nested.ans | 4 +- test/results/tag decorator.ans | 4 +- test/results/tag empty.ans | 4 +- test/results/tag operator.ans | 4 +- test/results/tag.ans | 4 +- test/results/text block.ans | 8 +-- test/results/text break.ans | 4 +- test/results/text buffer with tags.ans | 4 +- test/results/text buffer.ans | 4 +- test/results/text escaping.ans | 10 ++-- test/results/text format.ans | 2 +- ...t line interpolation with choice event.ans | 16 ++--- ...xt line interpolation with event flush.ans | 8 +-- ...ext line interpolation with text event.ans | 6 +- test/results/text.ans | 2 +- test/results/translate context.ans | 6 +- test/results/translate string.ans | 4 +- test/results/translate text attachblock.ans | 4 +- test/results/translate text.ans | 4 +- test/results/unary operator overload.ans | 6 +- test/results/while loop else.ans | 14 ++--- test/results/while loop.ans | 36 +++++------ 91 files changed, 428 insertions(+), 424 deletions(-) diff --git a/anselme/ast/Text.lua b/anselme/ast/Text.lua index 27a25c3..ce782df 100644 --- a/anselme/ast/Text.lua +++ b/anselme/ast/Text.lua @@ -25,7 +25,7 @@ return Runtime(AutoCall, Event) { for _, e in ipairs(self.list) do table.insert(t, ("%s%s"):format(e[2]:format(...), e[1]:format(...))) end - return ("| %s|"):format(table.concat(t, " ")) + return ("| %s |"):format(table.concat(t, " ")) end, -- Text comes from TextInterpolation which already evals the contents diff --git a/anselme/ast/TextInterpolation.lua b/anselme/ast/TextInterpolation.lua index 5a297b6..652e0c6 100644 --- a/anselme/ast/TextInterpolation.lua +++ b/anselme/ast/TextInterpolation.lua @@ -31,7 +31,7 @@ local TextInterpolation = ast.abstract.Node { table.insert(l, ("{%s}"):format(e:format(...))) end end - return ("| %s|"):format(table.concat(l)) + return ("| %s |"):format(table.concat(l)) end, _eval = function(self, state) diff --git a/anselme/parser/expression/primary/text.lua b/anselme/parser/expression/primary/text.lua index c6baffe..8b753e8 100644 --- a/anselme/parser/expression/primary/text.lua +++ b/anselme/parser/expression/primary/text.lua @@ -20,6 +20,10 @@ return string { source:increment(-1) end + -- remove terminal space + local last = interpolation.list[#interpolation.list] + if ast.String:is(last) then last.string = last.string:gsub("%s$", "") end + return Translatable:new(interpolation):set_source(start_source), rem end } diff --git a/test/results/binary operator overload.ans b/test/results/binary operator overload.ans index 6c06cf2..3b8a0c1 100644 --- a/test/results/binary operator overload.ans +++ b/test/results/binary operator overload.ans @@ -1,10 +1,10 @@ --# run #-- --- text --- -| {}"" {}"-3" {}""| +| {}"" {}"-3" {}"" | --- text --- -| {}"" {}"heh minus lol" {}""| +| {}"" {}"heh minus lol" {}"" | --- text --- -| {}"" {}"generic minus" {}""| +| {}"" {}"generic minus" {}"" | --- return --- () --# saved #-- diff --git a/test/results/binop assignement.ans b/test/results/binop assignement.ans index bb7482f..bc7e080 100644 --- a/test/results/binop assignement.ans +++ b/test/results/binop assignement.ans @@ -1,8 +1,8 @@ --# run #-- --- text --- -| {}"" {}"1" {}""| +| {}"" {}"1" {}"" | --- text --- -| {}"" {}"3" {}""| +| {}"" {}"3" {}"" | --- return --- () --# saved #-- diff --git a/test/results/choice block.ans b/test/results/choice block.ans index 9bdfa28..fe0e1b5 100644 --- a/test/results/choice block.ans +++ b/test/results/choice block.ans @@ -1,14 +1,14 @@ --# run #-- --- choice --- - > | {}"ye "| -=> | {}"ne "| + > | {}"ye" | +=> | {}"ne" | --- text --- -| {}"ok"| +| {}"ok" | --- choice --- -=> | {}"ho "| - > | {}"oh "| +=> | {}"ho" | + > | {}"oh" | --- text --- -| {}"plop"| +| {}"plop" | --- return --- () --# saved #-- diff --git a/test/results/choice function.ans b/test/results/choice function.ans index 8b60769..fb9287f 100644 --- a/test/results/choice function.ans +++ b/test/results/choice function.ans @@ -1,11 +1,11 @@ --# run #-- --- choice --- - > | {}"ho "| - > | {}"neol "| -=> | {}"oh "| - > | {}"neol "| + > | {}"ho" | + > | {}"neol" | +=> | {}"oh" | + > | {}"neol" | --- text --- -| {}"ok"| +| {}"ok" | --- return --- () --# saved #-- diff --git a/test/results/choice line interpolation with choice event.ans b/test/results/choice line interpolation with choice event.ans index 73e445c..b9f6422 100644 --- a/test/results/choice line interpolation with choice event.ans +++ b/test/results/choice line interpolation with choice event.ans @@ -1,10 +1,10 @@ --# run #-- --- text --- -| {1:1}"A"| +| {1:1}"A" | --- choice --- -=> | {}"Suprise choice! "| - > | {}"Press " {}"JOIN" {}" to jump. "| - > | {}"No "| +=> | {}"Suprise choice!" | + > | {}"Press " {}"JOIN" {}" to jump." | + > | {}"No" | --- return --- () --# saved #-- diff --git a/test/results/choice line interpolation with event flush.ans b/test/results/choice line interpolation with event flush.ans index 4a531ec..21b3091 100644 --- a/test/results/choice line interpolation with event flush.ans +++ b/test/results/choice line interpolation with event flush.ans @@ -1,11 +1,11 @@ --# run #-- --- text --- -| {1:1}"a"| +| {1:1}"a" | --- choice --- -=> | {}"Press " {}"SPLIT" {}" to jump. "| - > | {}"No "| +=> | {}"Press " {}"SPLIT" {}" to jump." | + > | {}"No" | --- text --- -| {}"ok"| +| {}"ok" | --- return --- () --# saved #-- diff --git a/test/results/choice line interpolation with text event.ans b/test/results/choice line interpolation with text event.ans index 8cdfe06..2cb1690 100644 --- a/test/results/choice line interpolation with text event.ans +++ b/test/results/choice line interpolation with text event.ans @@ -1,18 +1,18 @@ --# run #-- --- choice --- -=> | {}"Press " {1:1}"A" {}" to jump. "| - > | {}"No "| +=> | {}"Press " {1:1}"A" {}" to jump." | + > | {}"No" | --- text --- -| {}"ok"| +| {}"ok" | --- choice --- -=> | {}"Other "| +=> | {}"Other" | --- text --- -| {}"ok"| -| {1:1}"left"| +| {}"ok" | +| {1:1}"left" | --- choice --- -=> | {}"Use " {}" joystick" {}" to move. "| +=> | {}"Use " {}" joystick" {}" to move." | --- text --- -| {}"ko"| +| {}"ko" | --- return --- () --# saved #-- diff --git a/test/results/choice preserve tags.ans b/test/results/choice preserve tags.ans index 5c6ee43..79e803a 100644 --- a/test/results/choice preserve tags.ans +++ b/test/results/choice preserve tags.ans @@ -1,17 +1,17 @@ --# run #-- --- choice --- -=> | {1:42}"a "| - > | {}"c "| +=> | {1:42}"a" | + > | {}"c" | --- text --- -| {1:42}"b"| +| {1:42}"b" | --- choice --- -=> | {1:42}"a "| - > | {"k":"v"}"d "| +=> | {1:42}"a" | + > | {"k":"v"}"d" | --- text --- -| {1:42}"b"| -| {"k":"v"}"e"| +| {1:42}"b" | +| {"k":"v"}"e" | --- text --- -| {}"f"| +| {}"f" | --- return --- () --# saved #-- diff --git a/test/results/choice simple.ans b/test/results/choice simple.ans index 875c45a..bce4096 100644 --- a/test/results/choice simple.ans +++ b/test/results/choice simple.ans @@ -1,9 +1,9 @@ --# run #-- --- choice --- - > | {}"ye "| -=> | {}"ne "| + > | {}"ye" | +=> | {}"ne" | --- text --- -| {}"ok"| +| {}"ok" | --- return --- () --# saved #-- diff --git a/test/results/choice with decorators.ans b/test/results/choice with decorators.ans index 015b8b2..7314750 100644 --- a/test/results/choice with decorators.ans +++ b/test/results/choice with decorators.ans @@ -1,32 +1,32 @@ --# run #-- --- choice --- -=> | {}"a "| - > | {}"b "| +=> | {}"a" | + > | {}"b" | --- text --- -| {}"-> a"| +| {}"-> a" | --- choice --- - > | {}"a "| -=> | {}"b "| + > | {}"a" | +=> | {}"b" | --- text --- -| {}"-> b"| +| {}"-> b" | --- choice --- -=> | {}"b "| +=> | {}"b" | --- text --- -| {}"-> b"| +| {}"-> b" | --- choice --- - > | {}"a "| -=> | {1:25}"b "| + > | {}"a" | +=> | {1:25}"b" | --- text --- -| {1:25}"-> b"| +| {1:25}"-> b" | --- choice --- -=> | {1:3}"b "| +=> | {1:3}"b" | --- text --- -| {1:3}"-> b"| +| {1:3}"-> b" | --- choice --- -=> | {1:12}"a "| - > | {1:3}"b "| +=> | {1:12}"a" | + > | {1:3}"b" | --- text --- -| {1:12}"-> a"| +| {1:12}"-> a" | --- return --- () --# saved #-- diff --git a/test/results/closure.ans b/test/results/closure.ans index 79c09af..ac43e13 100644 --- a/test/results/closure.ans +++ b/test/results/closure.ans @@ -1,10 +1,10 @@ --# run #-- --- text --- -| {}"" {}"5" {}" = 5"| -| {}"" {}"8" {}" = 8"| +| {}"" {}"5" {}" = 5" | +| {}"" {}"8" {}" = 8" | --- text --- -| {}"" {}"4" {}" = 4"| -| {}"" {}"7" {}" = 7"| +| {}"" {}"4" {}" = 4" | +| {}"" {}"7" {}" = 7" | --- return --- () --# saved #-- diff --git a/test/results/condition decorator.ans b/test/results/condition decorator.ans index 637dcc7..383c4fa 100644 --- a/test/results/condition decorator.ans +++ b/test/results/condition decorator.ans @@ -1,7 +1,7 @@ --# run #-- --- text --- -| {}"ok"| -| {}"ok bis"| +| {}"ok" | +| {}"ok bis" | --- return --- () --# saved #-- diff --git a/test/results/condition else false.ans b/test/results/condition else false.ans index a0b55b3..220c410 100644 --- a/test/results/condition else false.ans +++ b/test/results/condition else false.ans @@ -1,6 +1,6 @@ --# run #-- --- text --- -| {}"ok"| +| {}"ok" | --- return --- () --# saved #-- diff --git a/test/results/condition else true.ans b/test/results/condition else true.ans index a0b55b3..220c410 100644 --- a/test/results/condition else true.ans +++ b/test/results/condition else true.ans @@ -1,6 +1,6 @@ --# run #-- --- text --- -| {}"ok"| +| {}"ok" | --- return --- () --# saved #-- diff --git a/test/results/condition elseif false.ans b/test/results/condition elseif false.ans index a0b55b3..220c410 100644 --- a/test/results/condition elseif false.ans +++ b/test/results/condition elseif false.ans @@ -1,6 +1,6 @@ --# run #-- --- text --- -| {}"ok"| +| {}"ok" | --- return --- () --# saved #-- diff --git a/test/results/condition elseif true.ans b/test/results/condition elseif true.ans index a0b55b3..220c410 100644 --- a/test/results/condition elseif true.ans +++ b/test/results/condition elseif true.ans @@ -1,6 +1,6 @@ --# run #-- --- text --- -| {}"ok"| +| {}"ok" | --- return --- () --# saved #-- diff --git a/test/results/condition operator.ans b/test/results/condition operator.ans index e522787..b40c44b 100644 --- a/test/results/condition operator.ans +++ b/test/results/condition operator.ans @@ -1,8 +1,8 @@ --# run #-- --- text --- -| {}"a " {}"b" {}" c"| +| {}"a " {}"b" {}" c" | --- text --- -| {}"a " {}"()" {}" c"| +| {}"a " {}"()" {}" c" | --- return --- () --# saved #-- diff --git a/test/results/condition true.ans b/test/results/condition true.ans index a0b55b3..220c410 100644 --- a/test/results/condition true.ans +++ b/test/results/condition true.ans @@ -1,6 +1,6 @@ --# run #-- --- text --- -| {}"ok"| +| {}"ok" | --- return --- () --# saved #-- diff --git a/test/results/constant variable list.ans b/test/results/constant variable list.ans index e1ded19..8162ae6 100644 --- a/test/results/constant variable list.ans +++ b/test/results/constant variable list.ans @@ -1,8 +1,8 @@ --# run #-- --- text --- -| {}"" {}"*[3]" {}""| +| {}"" {}"*[3]" {}"" | --- text --- -| {}"" {}"*[3, 52]" {}""| +| {}"" {}"*[3, 52]" {}"" | --- return --- () --# saved #-- diff --git a/test/results/constrained variable assignement.ans b/test/results/constrained variable assignement.ans index fe00758..8dd7d76 100644 --- a/test/results/constrained variable assignement.ans +++ b/test/results/constrained variable assignement.ans @@ -1,8 +1,8 @@ --# run #-- --- text --- -| {}"" {}"type(\"kg\", 5)" {}""| +| {}"" {}"type(\"kg\", 5)" {}"" | --- text --- -| {}"" {}"type(\"kg\", 12)" {}""| +| {}"" {}"type(\"kg\", 12)" {}"" | --- error --- type check failure for weigh; 32 does not satisfy ($(x) type(x) == t) ↳ from test/tests/constrained variable assignement.ans:9:7 in assignment: weigh = 32 diff --git a/test/results/constrained variable definition.ans b/test/results/constrained variable definition.ans index d6477a8..89ad27f 100644 --- a/test/results/constrained variable definition.ans +++ b/test/results/constrained variable definition.ans @@ -1,8 +1,8 @@ --# run #-- --- text --- -| {}"" {}"type(\"kg\", 5)" {}""| +| {}"" {}"type(\"kg\", 5)" {}"" | --- text --- -| {}"" {}"12" {}""| +| {}"" {}"12" {}"" | --- return --- () --# saved #-- diff --git a/test/results/custom text formatting.ans b/test/results/custom text formatting.ans index 86b806d..2ffbbd0 100644 --- a/test/results/custom text formatting.ans +++ b/test/results/custom text formatting.ans @@ -1,7 +1,7 @@ --# run #-- --- text --- | {}"" {}"\"Name: Darmanin\\\ -Age: 38\"" {}""| +Age: 38\"" {}"" | --- return --- () --# saved #-- diff --git a/test/results/equality operator.ans b/test/results/equality operator.ans index e8c3af5..d92f702 100644 --- a/test/results/equality operator.ans +++ b/test/results/equality operator.ans @@ -1,26 +1,26 @@ --# run #-- --- text --- -| {}"false = " {}"false" {}""| +| {}"false = " {}"false" {}"" | --- text --- -| {}"false = " {}"false" {}""| +| {}"false = " {}"false" {}"" | --- text --- -| {}"true = " {}"true" {}""| +| {}"true = " {}"true" {}"" | --- text --- -| {}"false = " {}"false" {}""| +| {}"false = " {}"false" {}"" | --- text --- -| {}"false = " {}"false" {}""| +| {}"false = " {}"false" {}"" | --- text --- -| {}"false = " {}"false" {}""| +| {}"false = " {}"false" {}"" | --- text --- -| {}"false = " {}"false" {}""| +| {}"false = " {}"false" {}"" | --- text --- -| {}"true = " {}"true" {}""| +| {}"true = " {}"true" {}"" | --- text --- -| {}"false = " {}"false" {}""| +| {}"false = " {}"false" {}"" | --- text --- -| {}"true = " {}"true" {}""| +| {}"true = " {}"true" {}"" | --- text --- -| {}"true = " {}"true" {}""| +| {}"true = " {}"true" {}"" | --- return --- () --# saved #-- diff --git a/test/results/flush.ans b/test/results/flush.ans index da34dbe..04a752a 100644 --- a/test/results/flush.ans +++ b/test/results/flush.ans @@ -1,12 +1,12 @@ --# run #-- --- text --- -| {}"a"| +| {}"a" | --- choice --- -=> | {}"b "| +=> | {}"b" | --- text --- -| {}"c"| +| {}"c" | --- choice --- -=> | {}"d "| +=> | {}"d" | --- return --- () --# saved #-- diff --git a/test/results/function arg.ans b/test/results/function arg.ans index a375adb..bb4c2e4 100644 --- a/test/results/function arg.ans +++ b/test/results/function arg.ans @@ -1,6 +1,6 @@ --# run #-- --- text --- -| {}"" {}"ok" {}""| +| {}"" {}"ok" {}"" | --- return --- () --# saved #-- diff --git a/test/results/function args.ans b/test/results/function args.ans index 694dc13..fcfa18d 100644 --- a/test/results/function args.ans +++ b/test/results/function args.ans @@ -1,6 +1,6 @@ --# run #-- --- text --- -| {}"" {}"o" {}"" {}"k" {}""| +| {}"" {}"o" {}"" {}"k" {}"" | --- return --- () --# saved #-- diff --git a/test/results/function assignement.ans b/test/results/function assignement.ans index 0a0b7d4..8ac9786 100644 --- a/test/results/function assignement.ans +++ b/test/results/function assignement.ans @@ -1,14 +1,14 @@ --# run #-- --- text --- -| {}"" {}"5" {}""| +| {}"" {}"5" {}"" | --- text --- -| {}"v=" {}"50" {}""| +| {}"v=" {}"50" {}"" | --- text --- -| {}"" {}"50" {}""| +| {}"" {}"50" {}"" | --- text --- -| {}"v2=" {}"ok" {}""| +| {}"v2=" {}"ok" {}"" | --- text --- -| {}"" {}"3" {}""| +| {}"" {}"3" {}"" | --- return --- () --# saved #-- diff --git a/test/results/function definition.ans b/test/results/function definition.ans index 83a0c6c..a358253 100644 --- a/test/results/function definition.ans +++ b/test/results/function definition.ans @@ -1,14 +1,14 @@ --# run #-- --- text --- -| {}"" {}"25" {}" = " {}"25" {}""| +| {}"" {}"25" {}" = " {}"25" {}"" | --- text --- -| {}"" {}"4" {}" = " {}"4" {}""| +| {}"" {}"4" {}" = " {}"4" {}"" | --- text --- -| {}"" {}"14" {}" == 14"| +| {}"" {}"14" {}" == 14" | --- text --- -| {}"" {}"32" {}" == 32"| +| {}"" {}"32" {}" == 32" | --- text --- -| {}"" {}"49" {}" == 49"| +| {}"" {}"49" {}" == 49" | --- return --- () --# saved #-- diff --git a/test/results/function exported.ans b/test/results/function exported.ans index 01c0f71..8595571 100644 --- a/test/results/function exported.ans +++ b/test/results/function exported.ans @@ -1,20 +1,20 @@ --# run #-- --- text --- -| {}"local:"| +| {}"local:" | --- text --- -| {}"" {}"1" {}""| +| {}"" {}"1" {}"" | --- text --- -| {}"" {}"1" {}""| +| {}"" {}"1" {}"" | --- text --- -| {}"" {}"1" {}""| +| {}"" {}"1" {}"" | --- text --- -| {}"exported:"| +| {}"exported:" | --- text --- -| {}"" {}"1" {}""| +| {}"" {}"1" {}"" | --- text --- -| {}"" {}"2" {}""| +| {}"" {}"2" {}"" | --- text --- -| {}"" {}"3" {}""| +| {}"" {}"3" {}"" | --- return --- () --# saved #-- diff --git a/test/results/function name dispatch.ans b/test/results/function name dispatch.ans index 7ecb4ec..746467d 100644 --- a/test/results/function name dispatch.ans +++ b/test/results/function name dispatch.ans @@ -1,8 +1,8 @@ --# run #-- --- text --- -| {}"a"| +| {}"a" | --- text --- -| {}"x"| +| {}"x" | --- return --- () --# saved #-- diff --git a/test/results/function return exit function nested.ans b/test/results/function return exit function nested.ans index bb6fb05..6fc7068 100644 --- a/test/results/function return exit function nested.ans +++ b/test/results/function return exit function nested.ans @@ -1,7 +1,7 @@ --# run #-- --- text --- -| {}"" {}"5" {}""| -| {}"" {}"2" {}""| +| {}"" {}"5" {}"" | +| {}"" {}"2" {}"" | --- return --- () --# saved #-- diff --git a/test/results/function return exit function.ans b/test/results/function return exit function.ans index 4b4989e..d4cd224 100644 --- a/test/results/function return exit function.ans +++ b/test/results/function return exit function.ans @@ -1,6 +1,6 @@ --# run #-- --- text --- -| {}"" {}"5" {}""| +| {}"" {}"5" {}"" | --- return --- () --# saved #-- diff --git a/test/results/function return nested.ans b/test/results/function return nested.ans index bb6fb05..6fc7068 100644 --- a/test/results/function return nested.ans +++ b/test/results/function return nested.ans @@ -1,7 +1,7 @@ --# run #-- --- text --- -| {}"" {}"5" {}""| -| {}"" {}"2" {}""| +| {}"" {}"5" {}"" | +| {}"" {}"2" {}"" | --- return --- () --# saved #-- diff --git a/test/results/function return.ans b/test/results/function return.ans index 4b4989e..d4cd224 100644 --- a/test/results/function return.ans +++ b/test/results/function return.ans @@ -1,6 +1,6 @@ --# run #-- --- text --- -| {}"" {}"5" {}""| +| {}"" {}"5" {}"" | --- return --- () --# saved #-- diff --git a/test/results/function scope wrong.ans b/test/results/function scope wrong.ans index a958b30..cd0f9ee 100644 --- a/test/results/function scope wrong.ans +++ b/test/results/function scope wrong.ans @@ -2,8 +2,8 @@ --- error --- identifier "b" is undefined in branch 0a138a38-3faa-4478-10f6f-1a9de1e0a8e1 ↳ from test/tests/function scope wrong.ans:4:7 in identifier: b - ↳ from test/tests/function scope wrong.ans:4:1 in text interpolation: | a: {b}| - ↳ from test/tests/function scope wrong.ans:4:1 in translatable: | a: {b}| + ↳ from test/tests/function scope wrong.ans:4:1 in text interpolation: | a: {b} | + ↳ from test/tests/function scope wrong.ans:4:1 in translatable: | a: {b} | ↳ from ? in block: :a = ($() _)… --# saved #-- {} \ No newline at end of file diff --git a/test/results/function scope.ans b/test/results/function scope.ans index bf77e30..cd6a042 100644 --- a/test/results/function scope.ans +++ b/test/results/function scope.ans @@ -1,6 +1,6 @@ --# run #-- --- text --- -| {}"a: " {}"5" {}""| +| {}"a: " {}"5" {}"" | --- return --- () --# saved #-- diff --git a/test/results/function scoped mutable.ans b/test/results/function scoped mutable.ans index 313fa5d..d6b20cc 100644 --- a/test/results/function scoped mutable.ans +++ b/test/results/function scoped mutable.ans @@ -1,64 +1,64 @@ --# run #-- --- text --- -| {}"new list each time:"| +| {}"new list each time:" | --- text --- -| {}"start: " {}"*[]" {}""| +| {}"start: " {}"*[]" {}"" | --- text --- -| {}"before recursion " {}"1" {}": " {}"*[1]" {}""| +| {}"before recursion " {}"1" {}": " {}"*[1]" {}"" | --- text --- -| {}"start: " {}"*[]" {}""| +| {}"start: " {}"*[]" {}"" | --- text --- -| {}"before recursion " {}"2" {}": " {}"*[2]" {}""| +| {}"before recursion " {}"2" {}": " {}"*[2]" {}"" | --- text --- -| {}"start: " {}"*[]" {}""| +| {}"start: " {}"*[]" {}"" | --- text --- -| {}"before recursion " {}"3" {}": " {}"*[3]" {}""| +| {}"before recursion " {}"3" {}": " {}"*[3]" {}"" | --- text --- -| {}"start: " {}"*[]" {}""| +| {}"start: " {}"*[]" {}"" | --- text --- -| {}"before recursion " {}"4" {}": " {}"*[4]" {}""| +| {}"before recursion " {}"4" {}": " {}"*[4]" {}"" | --- text --- -| {}"start: " {}"*[]" {}""| +| {}"start: " {}"*[]" {}"" | --- text --- -| {}"before recursion " {}"5" {}": " {}"*[5]" {}""| +| {}"before recursion " {}"5" {}": " {}"*[5]" {}"" | --- text --- -| {}"after recursion " {}"4" {}": " {}"*[4]" {}""| +| {}"after recursion " {}"4" {}": " {}"*[4]" {}"" | --- text --- -| {}"after recursion " {}"3" {}": " {}"*[3]" {}""| +| {}"after recursion " {}"3" {}": " {}"*[3]" {}"" | --- text --- -| {}"after recursion " {}"2" {}": " {}"*[2]" {}""| +| {}"after recursion " {}"2" {}": " {}"*[2]" {}"" | --- text --- -| {}"after recursion " {}"1" {}": " {}"*[1]" {}""| +| {}"after recursion " {}"1" {}": " {}"*[1]" {}"" | --- text --- -| {}"pass list:"| +| {}"pass list:" | --- text --- -| {}"start: " {}"*[]" {}""| +| {}"start: " {}"*[]" {}"" | --- text --- -| {}"before recursion " {}"1" {}": " {}"*[1]" {}""| +| {}"before recursion " {}"1" {}": " {}"*[1]" {}"" | --- text --- -| {}"start: " {}"*[1]" {}""| +| {}"start: " {}"*[1]" {}"" | --- text --- -| {}"before recursion " {}"2" {}": " {}"*[1, 2]" {}""| +| {}"before recursion " {}"2" {}": " {}"*[1, 2]" {}"" | --- text --- -| {}"start: " {}"*[1, 2]" {}""| +| {}"start: " {}"*[1, 2]" {}"" | --- text --- -| {}"before recursion " {}"3" {}": " {}"*[1, 2, 3]" {}""| +| {}"before recursion " {}"3" {}": " {}"*[1, 2, 3]" {}"" | --- text --- -| {}"start: " {}"*[1, 2, 3]" {}""| +| {}"start: " {}"*[1, 2, 3]" {}"" | --- text --- -| {}"before recursion " {}"4" {}": " {}"*[1, 2, 3, 4]" {}""| +| {}"before recursion " {}"4" {}": " {}"*[1, 2, 3, 4]" {}"" | --- text --- -| {}"start: " {}"*[1, 2, 3, 4]" {}""| +| {}"start: " {}"*[1, 2, 3, 4]" {}"" | --- text --- -| {}"before recursion " {}"5" {}": " {}"*[1, 2, 3, 4, 5]" {}""| +| {}"before recursion " {}"5" {}": " {}"*[1, 2, 3, 4, 5]" {}"" | --- text --- -| {}"after recursion " {}"4" {}": " {}"*[1, 2, 3, 4, 5]" {}""| +| {}"after recursion " {}"4" {}": " {}"*[1, 2, 3, 4, 5]" {}"" | --- text --- -| {}"after recursion " {}"3" {}": " {}"*[1, 2, 3, 4, 5]" {}""| +| {}"after recursion " {}"3" {}": " {}"*[1, 2, 3, 4, 5]" {}"" | --- text --- -| {}"after recursion " {}"2" {}": " {}"*[1, 2, 3, 4, 5]" {}""| +| {}"after recursion " {}"2" {}": " {}"*[1, 2, 3, 4, 5]" {}"" | --- text --- -| {}"after recursion " {}"1" {}": " {}"*[1, 2, 3, 4, 5]" {}""| +| {}"after recursion " {}"1" {}": " {}"*[1, 2, 3, 4, 5]" {}"" | --- return --- () --# saved #-- diff --git a/test/results/function scoped nested.ans b/test/results/function scoped nested.ans index 6e30fb1..af25ebe 100644 --- a/test/results/function scoped nested.ans +++ b/test/results/function scoped nested.ans @@ -1,60 +1,60 @@ --# run #-- --- text --- -| {}"depth 1:"| +| {}"depth 1:" | --- text --- -| {}"" {}"1" {}""| +| {}"" {}"1" {}"" | --- text --- -| {}"" {}">" {}" depth 2, unscoped:"| +| {}"" {}">" {}" depth 2, unscoped:" | --- text --- -| {}"" {}"1" {}""| +| {}"" {}"1" {}"" | --- text --- -| {}"" {}"1" {}""| +| {}"" {}"1" {}"" | --- text --- -| {}"" {}"1" {}""| +| {}"" {}"1" {}"" | --- text --- -| {}"" {}">" {}" depth 2, scoped:"| +| {}"" {}">" {}" depth 2, scoped:" | --- text --- -| {}"" {}"1" {}""| +| {}"" {}"1" {}"" | --- text --- -| {}"" {}"1" {}""| +| {}"" {}"1" {}"" | --- text --- -| {}"" {}"1" {}""| +| {}"" {}"1" {}"" | --- text --- -| {}"" {}"1" {}""| +| {}"" {}"1" {}"" | --- text --- -| {}"" {}">" {}" depth 2, unscoped:"| +| {}"" {}">" {}" depth 2, unscoped:" | --- text --- -| {}"" {}"1" {}""| +| {}"" {}"1" {}"" | --- text --- -| {}"" {}"1" {}""| +| {}"" {}"1" {}"" | --- text --- -| {}"" {}"1" {}""| +| {}"" {}"1" {}"" | --- text --- -| {}"" {}">" {}" depth 2, scoped:"| +| {}"" {}">" {}" depth 2, scoped:" | --- text --- -| {}"" {}"1" {}""| +| {}"" {}"1" {}"" | --- text --- -| {}"" {}"1" {}""| +| {}"" {}"1" {}"" | --- text --- -| {}"" {}"1" {}""| +| {}"" {}"1" {}"" | --- text --- -| {}"" {}"1" {}""| +| {}"" {}"1" {}"" | --- text --- -| {}"" {}">" {}" depth 2, unscoped:"| +| {}"" {}">" {}" depth 2, unscoped:" | --- text --- -| {}"" {}"1" {}""| +| {}"" {}"1" {}"" | --- text --- -| {}"" {}"1" {}""| +| {}"" {}"1" {}"" | --- text --- -| {}"" {}"1" {}""| +| {}"" {}"1" {}"" | --- text --- -| {}"" {}">" {}" depth 2, scoped:"| +| {}"" {}">" {}" depth 2, scoped:" | --- text --- -| {}"" {}"1" {}""| +| {}"" {}"1" {}"" | --- text --- -| {}"" {}"1" {}""| +| {}"" {}"1" {}"" | --- text --- -| {}"" {}"1" {}""| +| {}"" {}"1" {}"" | --- return --- () --# saved #-- diff --git a/test/results/function scoped recursive.ans b/test/results/function scoped recursive.ans index 09a9cff..2ef9e6f 100644 --- a/test/results/function scoped recursive.ans +++ b/test/results/function scoped recursive.ans @@ -1,32 +1,32 @@ --# run #-- --- text --- -| {}"start: " {}"1" {}""| +| {}"start: " {}"1" {}"" | --- text --- -| {}"before recursion " {}"1" {}": " {}"2" {}""| +| {}"before recursion " {}"1" {}": " {}"2" {}"" | --- text --- -| {}"start: " {}"1" {}""| +| {}"start: " {}"1" {}"" | --- text --- -| {}"before recursion " {}"2" {}": " {}"2" {}""| +| {}"before recursion " {}"2" {}": " {}"2" {}"" | --- text --- -| {}"start: " {}"1" {}""| +| {}"start: " {}"1" {}"" | --- text --- -| {}"before recursion " {}"3" {}": " {}"2" {}""| +| {}"before recursion " {}"3" {}": " {}"2" {}"" | --- text --- -| {}"start: " {}"1" {}""| +| {}"start: " {}"1" {}"" | --- text --- -| {}"before recursion " {}"4" {}": " {}"2" {}""| +| {}"before recursion " {}"4" {}": " {}"2" {}"" | --- text --- -| {}"start: " {}"1" {}""| +| {}"start: " {}"1" {}"" | --- text --- -| {}"before recursion " {}"5" {}": " {}"2" {}""| +| {}"before recursion " {}"5" {}": " {}"2" {}"" | --- text --- -| {}"after recursion " {}"4" {}": " {}"2" {}""| +| {}"after recursion " {}"4" {}": " {}"2" {}"" | --- text --- -| {}"after recursion " {}"3" {}": " {}"2" {}""| +| {}"after recursion " {}"3" {}": " {}"2" {}"" | --- text --- -| {}"after recursion " {}"2" {}": " {}"2" {}""| +| {}"after recursion " {}"2" {}": " {}"2" {}"" | --- text --- -| {}"after recursion " {}"1" {}": " {}"2" {}""| +| {}"after recursion " {}"1" {}": " {}"2" {}"" | --- return --- () --# saved #-- diff --git a/test/results/function scoped.ans b/test/results/function scoped.ans index a785596..03dc970 100644 --- a/test/results/function scoped.ans +++ b/test/results/function scoped.ans @@ -1,20 +1,20 @@ --# run #-- --- text --- -| {}"paren:"| +| {}"paren:" | --- text --- -| {}"" {}"1" {}""| +| {}"" {}"1" {}"" | --- text --- -| {}"" {}"1" {}""| +| {}"" {}"1" {}"" | --- text --- -| {}"" {}"1" {}""| +| {}"" {}"1" {}"" | --- text --- -| {}"no paren:"| +| {}"no paren:" | --- text --- -| {}"" {}"1" {}""| +| {}"" {}"1" {}"" | --- text --- -| {}"" {}"1" {}""| +| {}"" {}"1" {}"" | --- text --- -| {}"" {}"1" {}""| +| {}"" {}"1" {}"" | --- return --- () --# saved #-- diff --git a/test/results/function selection.ans b/test/results/function selection.ans index 7b82d73..200dae4 100644 --- a/test/results/function selection.ans +++ b/test/results/function selection.ans @@ -1,8 +1,8 @@ --# run #-- --- text --- -| {}"" {}"plopheh" {}""| +| {}"" {}"plopheh" {}"" | --- text --- -| {}"" {}"4" {}""| +| {}"" {}"4" {}"" | --- return --- () --# saved #-- diff --git a/test/results/function separate variable from variants.ans b/test/results/function separate variable from variants.ans index 16295b8..edafc7f 100644 --- a/test/results/function separate variable from variants.ans +++ b/test/results/function separate variable from variants.ans @@ -5,8 +5,8 @@ • (c::($(x) ), s::($(x) )) = v: expected 3 arguments, received 2 • (c::($(x) ), s::($(x) )): type check failure for parameter c in function (c::($(x) ), s::($(x) )) ↳ from test/tests/function separate variable from variants.ans:10:4 in call: f . "a" - ↳ from test/tests/function separate variable from variants.ans:10:1 in text interpolation: | {(f . "a")} = 2| - ↳ from test/tests/function separate variable from variants.ans:10:1 in translatable: | {(f . "a")} = 2| + ↳ from test/tests/function separate variable from variants.ans:10:1 in text interpolation: | {(f . "a")} = 2 | + ↳ from test/tests/function separate variable from variants.ans:10:1 in translatable: | {(f . "a")} = 2 | ↳ from ? in block: :f = ($() _)… --# saved #-- {} \ No newline at end of file diff --git a/test/results/function type dispatch with default.ans b/test/results/function type dispatch with default.ans index 8088f5f..043bb87 100644 --- a/test/results/function type dispatch with default.ans +++ b/test/results/function type dispatch with default.ans @@ -1,19 +1,19 @@ --# run #-- --- text --- -| {}"a"| +| {}"a" | --- text --- -| {}"x"| +| {}"x" | --- text --- -| {}"a"| +| {}"a" | --- text --- -| {}"" {}"gs" {}""| -| {}"" {}"gn" {}""| -| {}"" {}"gs" {}""| -| {}"" {}"gn" {}""| -| {}"" {}"gs" {}""| -| {}"" {}"gn" {}""| -| {}"" {}"gs" {}""| -| {}"" {}"gn" {}""| +| {}"" {}"gs" {}"" | +| {}"" {}"gn" {}"" | +| {}"" {}"gs" {}"" | +| {}"" {}"gn" {}"" | +| {}"" {}"gs" {}"" | +| {}"" {}"gn" {}"" | +| {}"" {}"gs" {}"" | +| {}"" {}"gn" {}"" | --- return --- () --# saved #-- diff --git a/test/results/function type dispatch.ans b/test/results/function type dispatch.ans index 7ecb4ec..746467d 100644 --- a/test/results/function type dispatch.ans +++ b/test/results/function type dispatch.ans @@ -1,8 +1,8 @@ --# run #-- --- text --- -| {}"a"| +| {}"a" | --- text --- -| {}"x"| +| {}"x" | --- return --- () --# saved #-- diff --git a/test/results/function ufcs arg.ans b/test/results/function ufcs arg.ans index 8fd7aa1..bc677a3 100644 --- a/test/results/function ufcs arg.ans +++ b/test/results/function ufcs arg.ans @@ -1,8 +1,8 @@ --# run #-- --- text --- -| {}"" {}"ok" {}""| +| {}"" {}"ok" {}"" | --- text --- -| {}"" {}"ok" {}""| +| {}"" {}"ok" {}"" | --- return --- () --# saved #-- diff --git a/test/results/function ufcs args.ans b/test/results/function ufcs args.ans index 694dc13..fcfa18d 100644 --- a/test/results/function ufcs args.ans +++ b/test/results/function ufcs args.ans @@ -1,6 +1,6 @@ --# run #-- --- text --- -| {}"" {}"o" {}"" {}"k" {}""| +| {}"" {}"o" {}"" {}"k" {}"" | --- return --- () --# saved #-- diff --git a/test/results/function.ans b/test/results/function.ans index b634ff6..d36e805 100644 --- a/test/results/function.ans +++ b/test/results/function.ans @@ -1,8 +1,8 @@ --# run #-- --- text --- -| {}"ok"| +| {}"ok" | --- text --- -| {}"ok2"| +| {}"ok2" | --- return --- () --# saved #-- diff --git a/test/results/implicit multiplication.ans b/test/results/implicit multiplication.ans index a184400..000ca7d 100644 --- a/test/results/implicit multiplication.ans +++ b/test/results/implicit multiplication.ans @@ -1,14 +1,14 @@ --# run #-- --- text --- -| {}"" {}"8" {}" = 8"| +| {}"" {}"8" {}" = 8" | --- text --- -| {}"" {}"12" {}" = 12"| +| {}"" {}"12" {}" = 12" | --- text --- -| {}"" {}"6.28" {}" = 2pi"| +| {}"" {}"6.28" {}" = 2pi" | --- text --- -| {}"" {}"0.125" {}" = 0.125"| +| {}"" {}"0.125" {}" = 0.125" | --- text --- -| {}"" {}"2.1" {}" = 2.1"| +| {}"" {}"2.1" {}" = 2.1" | --- return --- () --# saved #-- diff --git a/test/results/lazy boolean operators.ans b/test/results/lazy boolean operators.ans index 45e3ba9..7ebf2e0 100644 --- a/test/results/lazy boolean operators.ans +++ b/test/results/lazy boolean operators.ans @@ -1,32 +1,32 @@ --# run #-- --- text --- -| {}"a"| -| {}"b"| -| {}"" {}"()" {}" = a b ()"| +| {}"a" | +| {}"b" | +| {}"" {}"()" {}" = a b ()" | --- text --- -| {}"b"| -| {}"" {}"()" {}" = b ()"| +| {}"b" | +| {}"" {}"()" {}" = b ()" | --- text --- -| {}"a"| -| {}"a"| -| {}"" {}"1" {}" = a a 1"| +| {}"a" | +| {}"a" | +| {}"" {}"1" {}" = a a 1" | --- text --- -| {}"b"| -| {}"" {}"()" {}" = b ()"| +| {}"b" | +| {}"" {}"()" {}" = b ()" | --- text --- -| {}"a"| -| {}"" {}"1" {}" = a 1"| +| {}"a" | +| {}"" {}"1" {}" = a 1" | --- text --- -| {}"b"| -| {}"a"| -| {}"" {}"1" {}" = b a 1"| +| {}"b" | +| {}"a" | +| {}"" {}"1" {}" = b a 1" | --- text --- -| {}"a"| -| {}"" {}"1" {}" = a 1"| +| {}"a" | +| {}"" {}"1" {}" = a 1" | --- text --- -| {}"b"| -| {}"b"| -| {}"" {}"()" {}" = b b ()"| +| {}"b" | +| {}"b" | +| {}"" {}"()" {}" = b b ()" | --- return --- () --# saved #-- diff --git a/test/results/list assignement.ans b/test/results/list assignement.ans index c25f8b1..327cc09 100644 --- a/test/results/list assignement.ans +++ b/test/results/list assignement.ans @@ -1,14 +1,14 @@ --# run #-- --- text --- -| {}"" {}"*[1, 2]" {}""| +| {}"" {}"*[1, 2]" {}"" | --- text --- -| {}"" {}"*[3, 2]" {}""| +| {}"" {}"*[3, 2]" {}"" | --- text --- -| {}"" {}"*[3, 5]" {}""| +| {}"" {}"*[3, 5]" {}"" | --- text --- -| {}"" {}"*[3, 12]" {}""| +| {}"" {}"*[3, 12]" {}"" | --- text --- -| {}"" {}"*[3, 12, 99]" {}""| +| {}"" {}"*[3, 12, 99]" {}"" | --- error --- list index out of bounds ↳ from test/tests/list assignement.ans:21:6 in call: x(5) = 0 diff --git a/test/results/list index.ans b/test/results/list index.ans index 51a5ad5..42d485e 100644 --- a/test/results/list index.ans +++ b/test/results/list index.ans @@ -1,17 +1,17 @@ --# run #-- --- text --- -| {}"" {}"[1, 2, 3]" {}""| +| {}"" {}"[1, 2, 3]" {}"" | --- text --- -| {}"" {}"1" {}" == " {}"1" {}""| +| {}"" {}"1" {}" == " {}"1" {}"" | --- text --- -| {}"" {}"2" {}" == " {}"2" {}""| +| {}"" {}"2" {}" == " {}"2" {}"" | --- text --- -| {}"" {}"3" {}" == " {}"3" {}""| +| {}"" {}"3" {}" == " {}"3" {}"" | --- error --- tuple index out of bounds ↳ from test/tests/list index.ans:11:4 in call: x(-4) - ↳ from test/tests/list index.ans:11:1 in text interpolation: | {x(-4)}| - ↳ from test/tests/list index.ans:11:1 in translatable: | {x(-4)}| + ↳ from test/tests/list index.ans:11:1 in text interpolation: | {x(-4)} | + ↳ from test/tests/list index.ans:11:1 in translatable: | {x(-4)} | ↳ from ? in block: :x = [1, 2, 3]… --# saved #-- {} \ No newline at end of file diff --git a/test/results/loop decorator.ans b/test/results/loop decorator.ans index 3232840..ffd7c0a 100644 --- a/test/results/loop decorator.ans +++ b/test/results/loop decorator.ans @@ -1,27 +1,27 @@ --# run #-- --- text --- | {}"" {}"1" {}"" {}"\ -" {}""| +" {}"" | | {}"" {}"2" {}"" {}"\ -" {}""| +" {}"" | | {}"" {}"3" {}"" {}"\ -" {}""| +" {}"" | | {}"" {}"4" {}"" {}"\ -" {}""| +" {}"" | | {}"" {}"5" {}"" {}"\ -" {}""| +" {}"" | | {}"" {}"6" {}"" {}"\ -" {}""| +" {}"" | | {}"" {}"7" {}"" {}"\ -" {}""| +" {}"" | | {}"" {}"8" {}"" {}"\ -" {}""| +" {}"" | | {}"" {}"9" {}"" {}"\ -" {}""| +" {}"" | | {}"" {}"10" {}"" {}"\ -" {}""| +" {}"" | --- text --- -| {}"" {}"11" {}""| +| {}"" {}"11" {}"" | --- return --- () --# saved #-- diff --git a/test/results/map assignement.ans b/test/results/map assignement.ans index 11360c0..02f4e31 100644 --- a/test/results/map assignement.ans +++ b/test/results/map assignement.ans @@ -1,22 +1,22 @@ --# run #-- --- text --- -| {}"" {}"*{1:1, 2:2}" {}""| +| {}"" {}"*{1:1, 2:2}" {}"" | --- text --- -| {}"" {}"()" {}""| +| {}"" {}"()" {}"" | --- text --- -| {}"" {}"*{1:3, 2:2}" {}""| +| {}"" {}"*{1:3, 2:2}" {}"" | --- text --- -| {}"" {}"()" {}""| +| {}"" {}"()" {}"" | --- text --- -| {}"" {}"*{\"foo\":\"a\", 1:3, 2:2}" {}""| +| {}"" {}"*{\"foo\":\"a\", 1:3, 2:2}" {}"" | --- text --- -| {}"" {}"()" {}""| +| {}"" {}"()" {}"" | --- text --- -| {}"" {}"*{\"bar\":\"b\", \"foo\":\"a\", 1:3, 2:2}" {}""| +| {}"" {}"*{\"bar\":\"b\", \"foo\":\"a\", 1:3, 2:2}" {}"" | --- text --- -| {}"" {}"()" {}""| +| {}"" {}"()" {}"" | --- text --- -| {}"" {}"*{\"bar\":\"b\", \"foo\":\"c\", 1:3, 2:2}" {}""| +| {}"" {}"*{\"bar\":\"b\", \"foo\":\"c\", 1:3, 2:2}" {}"" | --- return --- () --# saved #-- diff --git a/test/results/map index.ans b/test/results/map index.ans index 9b7f00a..91eedf4 100644 --- a/test/results/map index.ans +++ b/test/results/map index.ans @@ -1,10 +1,10 @@ --# run #-- --- text --- -| {}"" {}"{\"ahah\":23, \"k\":23, 3:12}" {}" == " {}"{" {}"3=12, ahah=23, k=23}"| +| {}"" {}"{\"ahah\":23, \"k\":23, 3:12}" {}" == " {}"{" {}"3=12, ahah=23, k=23}" | --- text --- -| {}"" {}"12" {}" == 12"| +| {}"" {}"12" {}" == 12" | --- text --- -| {}"" {}"23" {}" == 23"| +| {}"" {}"23" {}" == 23" | --- return --- () --# saved #-- diff --git a/test/results/named arguments.ans b/test/results/named arguments.ans index 30b922f..2bfe891 100644 --- a/test/results/named arguments.ans +++ b/test/results/named arguments.ans @@ -1,6 +1,6 @@ --# run #-- --- text --- -| {}"" {}"abc" {}" = " {}"abc" {}" = " {}"abc" {}""| +| {}"" {}"abc" {}" = " {}"abc" {}" = " {}"abc" {}"" | --- return --- () --# saved #-- diff --git a/test/results/namespace operator arbitrary expression.ans b/test/results/namespace operator arbitrary expression.ans index 4b4989e..d4cd224 100644 --- a/test/results/namespace operator arbitrary expression.ans +++ b/test/results/namespace operator arbitrary expression.ans @@ -1,6 +1,6 @@ --# run #-- --- text --- -| {}"" {}"5" {}""| +| {}"" {}"5" {}"" | --- return --- () --# saved #-- diff --git a/test/results/nested conditions.ans b/test/results/nested conditions.ans index c63108b..1b5802c 100644 --- a/test/results/nested conditions.ans +++ b/test/results/nested conditions.ans @@ -1,9 +1,9 @@ --# run #-- --- text --- -| {}"yes"| +| {}"yes" | --- text --- -| {}"ye"| -| {}"da"| +| {}"ye" | +| {}"da" | --- return --- () --# saved #-- diff --git a/test/results/nested flush.ans b/test/results/nested flush.ans index 485ca0c..3934952 100644 --- a/test/results/nested flush.ans +++ b/test/results/nested flush.ans @@ -1,19 +1,19 @@ --# run #-- --- text --- -| {}"a"| +| {}"a" | --- text --- -| {}"b"| +| {}"b" | --- text --- -| {}"c"| -| {}"d"| +| {}"c" | +| {}"d" | --- text --- -| {}"e"| +| {}"e" | --- choice --- -=> | {}"f "| +=> | {}"f" | --- text --- -| {}"g"| +| {}"g" | --- choice --- -=> | {}"h "| +=> | {}"h" | --- return --- () --# saved #-- diff --git a/test/results/optional arguments.ans b/test/results/optional arguments.ans index 30b922f..2bfe891 100644 --- a/test/results/optional arguments.ans +++ b/test/results/optional arguments.ans @@ -1,6 +1,6 @@ --# run #-- --- text --- -| {}"" {}"abc" {}" = " {}"abc" {}" = " {}"abc" {}""| +| {}"" {}"abc" {}" = " {}"abc" {}" = " {}"abc" {}"" | --- return --- () --# saved #-- diff --git a/test/results/pair operator.ans b/test/results/pair operator.ans index b141e43..5c5afbd 100644 --- a/test/results/pair operator.ans +++ b/test/results/pair operator.ans @@ -1,8 +1,8 @@ --# run #-- --- text --- -| {}"" {}"[\"test\":1, 3:\"p\", \"test\":\"foo\", \"ho\":\"ah\", \"test\":\"test\"]" {}""| +| {}"" {}"[\"test\":1, 3:\"p\", \"test\":\"foo\", \"ho\":\"ah\", \"test\":\"test\"]" {}"" | --- text --- -| {}"" {}"[\"name\":1, 3:\"p\", \"test\":\"foo\", \"ho\":\"ah\", \"name\":\"test\"]" {}""| +| {}"" {}"[\"name\":1, 3:\"p\", \"test\":\"foo\", \"ho\":\"ah\", \"name\":\"test\"]" {}"" | --- return --- () --# saved #-- diff --git a/test/results/persist.ans b/test/results/persist.ans index 8b8b478..f36e54e 100644 --- a/test/results/persist.ans +++ b/test/results/persist.ans @@ -1,12 +1,12 @@ --# run #-- --- text --- -| {}"pouet=" {}"7" {}" (7)"| +| {}"pouet=" {}"7" {}" (7)" | --- text --- -| {}"d=" {}"7" {}" (7)"| +| {}"d=" {}"7" {}" (7)" | --- text --- -| {}"d=" {}"9" {}" (9)"| +| {}"d=" {}"9" {}" (9)" | --- text --- -| {}"pouet=" {}"9" {}" (9)"| +| {}"pouet=" {}"9" {}" (9)" | --- return --- () --# saved #-- diff --git a/test/results/resume anchors.ans b/test/results/resume anchors.ans index 0f13d5f..ac70db4 100644 --- a/test/results/resume anchors.ans +++ b/test/results/resume anchors.ans @@ -1,36 +1,36 @@ --# run #-- --- text --- -| {}"<<>>"| -| {}"a"| +| {}"<<>>" | +| {}"a" | --- choice --- - > | {}"A "| -=> | {}"B "| + > | {}"A" | +=> | {}"B" | --- text --- -| {}"boum"| -| {}"h " {}"8" {}""| +| {}"boum" | +| {}"h " {}"8" {}"" | --- text --- -| {}"<<>>"| -| {}"a"| +| {}"<<>>" | +| {}"a" | --- choice --- -=> | {}"A "| - > | {}"B "| +=> | {}"A" | + > | {}"B" | --- text --- -| {}"b"| -| {}"c"| -| {}"d"| -| {}"e"| -| {}"f"| -| {}"g"| -| {}"h " {}"8" {}""| +| {}"b" | +| {}"c" | +| {}"d" | +| {}"e" | +| {}"f" | +| {}"g" | +| {}"h " {}"8" {}"" | --- text --- -| {}"<<>>"| -| {}"c"| -| {}"d"| -| {}"e"| -| {}"f"| -| {}"g"| +| {}"<<>>" | +| {}"c" | +| {}"d" | +| {}"e" | +| {}"f" | +| {}"g" | --- text --- -| {}"h " {}"8" {}""| +| {}"h " {}"8" {}"" | --- return --- () --# saved #-- diff --git a/test/results/return children.ans b/test/results/return children.ans index 64ca15d..052e641 100644 --- a/test/results/return children.ans +++ b/test/results/return children.ans @@ -1,8 +1,8 @@ --# run #-- --- text --- -| {}"" {}"50" {}" = 50"| +| {}"" {}"50" {}" = 50" | --- text --- -| {}"" {}"3" {}" = 3"| +| {}"" {}"3" {}" = 3" | --- return --- () --# saved #-- diff --git a/test/results/return in choice.ans b/test/results/return in choice.ans index 58b64b3..026ce12 100644 --- a/test/results/return in choice.ans +++ b/test/results/return in choice.ans @@ -1,9 +1,9 @@ --# run #-- --- choice --- -=> | {}"a "| +=> | {}"a" | --- text --- -| {}"x"| -| {}"Yes."| +| {}"x" | +| {}"Yes." | --- return --- () --# saved #-- diff --git a/test/results/string escaping.ans b/test/results/string escaping.ans index f2380d9..eba151f 100644 --- a/test/results/string escaping.ans +++ b/test/results/string escaping.ans @@ -1,13 +1,13 @@ --# run #-- --- text --- -| {}"expression " {}"a" {}""| +| {}"expression " {}"a" {}"" | --- text --- -| {}"quote " {}"\"" {}""| +| {}"quote " {}"\"" {}"" | --- text --- | {}"other codes " {}"\ -" {}" " {}"\\" {}" " {}"\9" {}" " {}"{" {}"braces}"| +" {}" " {}"\\" {}" " {}"\9" {}" " {}"{" {}"braces}" | --- text --- -| {}"" {}"escaping expressions abc and {stuff} \\ and quotes \"" {}""| +| {}"" {}"escaping expressions abc and {stuff} \\ and quotes \"" {}"" | --- return --- () --# saved #-- diff --git a/test/results/symbol alias.ans b/test/results/symbol alias.ans index fa61347..6be1c1d 100644 --- a/test/results/symbol alias.ans +++ b/test/results/symbol alias.ans @@ -1,10 +1,10 @@ --# run #-- --- text --- -| {}"c=" {}"2" {}" (2)"| -| {}"l=" {}"*[1, 2, 3]" {}" (*[1,2,3])"| +| {}"c=" {}"2" {}" (2)" | +| {}"l=" {}"*[1, 2, 3]" {}" (*[1,2,3])" | --- text --- -| {}"c=" {}"5" {}" (5)"| -| {}"l=" {}"*[1, 5, 3]" {}" (*[1,5,3])"| +| {}"c=" {}"5" {}" (5)" | +| {}"l=" {}"*[1, 5, 3]" {}" (*[1,5,3])" | --- return --- () --# saved #-- diff --git a/test/results/tag decorator nested.ans b/test/results/tag decorator nested.ans index e8e1222..bbba11f 100644 --- a/test/results/tag decorator nested.ans +++ b/test/results/tag decorator nested.ans @@ -1,7 +1,7 @@ --# run #-- --- text --- -| {1:1}"foo"| -| {"a":[2, 3], "b":[1, 2], 1:1}"bar"| +| {1:1}"foo" | +| {"a":[2, 3], "b":[1, 2], 1:1}"bar" | --- return --- () --# saved #-- diff --git a/test/results/tag decorator.ans b/test/results/tag decorator.ans index cca8490..98ee078 100644 --- a/test/results/tag decorator.ans +++ b/test/results/tag decorator.ans @@ -1,7 +1,7 @@ --# run #-- --- text --- -| {1:1}"foo"| -| {"a":[2, 3], 1:1}"bar"| +| {1:1}"foo" | +| {"a":[2, 3], 1:1}"bar" | --- return --- () --# saved #-- diff --git a/test/results/tag empty.ans b/test/results/tag empty.ans index 423d1d6..444e537 100644 --- a/test/results/tag empty.ans +++ b/test/results/tag empty.ans @@ -1,7 +1,7 @@ --# run #-- --- text --- -| {1:1}"foo"| -| {1:1}"bar"| +| {1:1}"foo" | +| {1:1}"bar" | --- return --- () --# saved #-- diff --git a/test/results/tag operator.ans b/test/results/tag operator.ans index 4f41cdd..73415c5 100644 --- a/test/results/tag operator.ans +++ b/test/results/tag operator.ans @@ -1,8 +1,8 @@ --# run #-- --- text --- -| {}"a " {1:5}"" {1:5}"b" {1:5}"" {}" c"| +| {}"a " {1:5}"" {1:5}"b" {1:5}"" {}" c" | --- text --- -| {2:2}"a " {1:5, 2:2}"" {1:5, 2:2}"b" {1:5, 2:2}"" {2:2}" c"| +| {2:2}"a " {1:5, 2:2}"" {1:5, 2:2}"b" {1:5, 2:2}"" {2:2}" c" | --- return --- () --# saved #-- diff --git a/test/results/tag.ans b/test/results/tag.ans index cca8490..98ee078 100644 --- a/test/results/tag.ans +++ b/test/results/tag.ans @@ -1,7 +1,7 @@ --# run #-- --- text --- -| {1:1}"foo"| -| {"a":[2, 3], 1:1}"bar"| +| {1:1}"foo" | +| {"a":[2, 3], 1:1}"bar" | --- return --- () --# saved #-- diff --git a/test/results/text block.ans b/test/results/text block.ans index 3ae3107..d8d5b44 100644 --- a/test/results/text block.ans +++ b/test/results/text block.ans @@ -1,10 +1,10 @@ --# run #-- --- text --- -| {}"a"| -| {}"b c"| +| {}"a" | +| {}"b c" | --- text --- -| {}"a"| -| {}"b c"| +| {}"a" | +| {}"b c" | --- return --- () --# saved #-- diff --git a/test/results/text break.ans b/test/results/text break.ans index f691669..f1980de 100644 --- a/test/results/text break.ans +++ b/test/results/text break.ans @@ -1,8 +1,8 @@ --# run #-- --- text --- -| {}"a"| +| {}"a" | --- text --- -| {}"b c"| +| {}"b c" | --- return --- () --# saved #-- diff --git a/test/results/text buffer with tags.ans b/test/results/text buffer with tags.ans index 9d861b1..55fbbfa 100644 --- a/test/results/text buffer with tags.ans +++ b/test/results/text buffer with tags.ans @@ -1,7 +1,7 @@ --# run #-- --- text --- -| {1:1}"lol"| +| {1:1}"lol" | --- return --- -@| {}"a " {1:2}"d" {}" " {1:3}"t" {}" b"| +@| {}"a " {1:2}"d" {}" " {1:3}"t" {}" b" | --# saved #-- {} \ No newline at end of file diff --git a/test/results/text buffer.ans b/test/results/text buffer.ans index 2657e45..7d7c971 100644 --- a/test/results/text buffer.ans +++ b/test/results/text buffer.ans @@ -1,7 +1,7 @@ --# run #-- --- text --- -| {}"lol"| +| {}"lol" | --- return --- -@| {}"a " {}"d" {}" b"| +@| {}"a " {}"d" {}" b" | --# saved #-- {} \ No newline at end of file diff --git a/test/results/text escaping.ans b/test/results/text escaping.ans index 8f1b040..8a2950a 100644 --- a/test/results/text escaping.ans +++ b/test/results/text escaping.ans @@ -1,15 +1,15 @@ --# run #-- --- text --- -| {}"expression " {}"{" {}"a}"| +| {}"expression " {}"{" {}"a}" | --- text --- -| {}"quote " {}"\"" {}""| +| {}"quote " {}"\"" {}"" | --- text --- | {}"other codes " {}"\ -" {}" " {}"\\" {}" " {}"\9" {}""| +" {}" " {}"\\" {}" " {}"\9" {}"" | --- text --- -| {}"decorators " {}"#" {}" tag " {}"~" {}" condition " {}"$" {}" fn"| +| {}"decorators " {}"#" {}" tag " {}"~" {}" condition " {}"$" {}" fn" | --- text --- -| {}"sub " {}"[" {}"text]"| +| {}"sub " {}"[" {}"text]" | --- return --- () --# saved #-- diff --git a/test/results/text format.ans b/test/results/text format.ans index bf77e30..cd6a042 100644 --- a/test/results/text format.ans +++ b/test/results/text format.ans @@ -1,6 +1,6 @@ --# run #-- --- text --- -| {}"a: " {}"5" {}""| +| {}"a: " {}"5" {}"" | --- return --- () --# saved #-- diff --git a/test/results/text line interpolation with choice event.ans b/test/results/text line interpolation with choice event.ans index 27b79fd..863be39 100644 --- a/test/results/text line interpolation with choice event.ans +++ b/test/results/text line interpolation with choice event.ans @@ -1,18 +1,18 @@ --# run #-- --- text --- -| {1:1}"A"| +| {1:1}"A" | --- choice --- -=> | {}"Surprise choice! "| +=> | {}"Surprise choice!" | --- text --- -| {}"ok"| -| {}"Press " {}"()" {}" to jump."| +| {}"ok" | +| {}"Press " {}"()" {}" to jump." | --- text --- -| {1:1}"left"| +| {1:1}"left" | --- choice --- -=> | {}"Surprise choice! "| +=> | {}"Surprise choice!" | --- text --- -| {}"ok2"| -| {}"Use " {}" joystick" {}" to move."| +| {}"ok2" | +| {}"Use " {}" joystick" {}" to move." | --- return --- () --# saved #-- diff --git a/test/results/text line interpolation with event flush.ans b/test/results/text line interpolation with event flush.ans index b6f9493..ca96839 100644 --- a/test/results/text line interpolation with event flush.ans +++ b/test/results/text line interpolation with event flush.ans @@ -1,12 +1,12 @@ --# run #-- --- text --- -| {1:1}"A"| +| {1:1}"A" | --- text --- -| {}"Press " {}"()" {}" to jump."| +| {}"Press " {}"()" {}" to jump." | --- text --- -| {1:1}"left"| +| {1:1}"left" | --- text --- -| {}"Use " {}" joystick" {}" to move."| +| {}"Use " {}" joystick" {}" to move." | --- return --- () --# saved #-- diff --git a/test/results/text line interpolation with text event.ans b/test/results/text line interpolation with text event.ans index ca8a07b..fd070ea 100644 --- a/test/results/text line interpolation with text event.ans +++ b/test/results/text line interpolation with text event.ans @@ -1,9 +1,9 @@ --# run #-- --- text --- -| {}"Press " {1:1}"A" {}" to jump."| +| {}"Press " {1:1}"A" {}" to jump." | --- text --- -| {1:2}"left"| -| {}"Use " {}" joystick" {}" to move."| +| {1:2}"left" | +| {}"Use " {}" joystick" {}" to move." | --- return --- () --# saved #-- diff --git a/test/results/text.ans b/test/results/text.ans index 05ec984..637daa7 100644 --- a/test/results/text.ans +++ b/test/results/text.ans @@ -1,6 +1,6 @@ --# run #-- --- text --- -| {}"a"| +| {}"a" | --- return --- () --# saved #-- diff --git a/test/results/translate context.ans b/test/results/translate context.ans index c76ecc7..d4854ee 100644 --- a/test/results/translate context.ans +++ b/test/results/translate context.ans @@ -1,10 +1,10 @@ --# run #-- --- text --- -| {}"Hello"| +| {}"Hello" | --- text --- -| {}"Bonjour"| +| {}"Bonjour" | --- text --- -| {}"Hello"| +| {}"Hello" | --- return --- () --# saved #-- diff --git a/test/results/translate string.ans b/test/results/translate string.ans index 34c794f..acff3db 100644 --- a/test/results/translate string.ans +++ b/test/results/translate string.ans @@ -1,8 +1,8 @@ --# run #-- --- text --- -| {}"" {}"Hello" {}""| +| {}"" {}"Hello" {}"" | --- text --- -| {}"" {}"Bonjour" {}""| +| {}"" {}"Bonjour" {}"" | --- return --- () --# saved #-- diff --git a/test/results/translate text attachblock.ans b/test/results/translate text attachblock.ans index 0c9983f..1aa9032 100644 --- a/test/results/translate text attachblock.ans +++ b/test/results/translate text attachblock.ans @@ -1,8 +1,8 @@ --# run #-- --- text --- -| {}"Hello"| +| {}"Hello" | --- text --- -| {}"Bonjour"| +| {}"Bonjour" | --- return --- () --# saved #-- diff --git a/test/results/translate text.ans b/test/results/translate text.ans index 0c9983f..1aa9032 100644 --- a/test/results/translate text.ans +++ b/test/results/translate text.ans @@ -1,8 +1,8 @@ --# run #-- --- text --- -| {}"Hello"| +| {}"Hello" | --- text --- -| {}"Bonjour"| +| {}"Bonjour" | --- return --- () --# saved #-- diff --git a/test/results/unary operator overload.ans b/test/results/unary operator overload.ans index 5257364..7786fb8 100644 --- a/test/results/unary operator overload.ans +++ b/test/results/unary operator overload.ans @@ -1,10 +1,10 @@ --# run #-- --- text --- -| {}"" {}"-5" {}""| +| {}"" {}"-5" {}"" | --- text --- -| {}"" {}"minus lol" {}""| +| {}"" {}"minus lol" {}"" | --- text --- -| {}"" {}"generic minus" {}""| +| {}"" {}"generic minus" {}"" | --- return --- () --# saved #-- diff --git a/test/results/while loop else.ans b/test/results/while loop else.ans index f85c5f8..bf30bfd 100644 --- a/test/results/while loop else.ans +++ b/test/results/while loop else.ans @@ -1,18 +1,18 @@ --# run #-- --- text --- -| {}"Start with i=" {}"1" {}":"| +| {}"Start with i=" {}"1" {}":" | --- text --- -| {}"" {}"1" {}""| +| {}"" {}"1" {}"" | --- text --- -| {}"" {}"2" {}""| +| {}"" {}"2" {}"" | --- text --- -| {}"" {}"3" {}""| +| {}"" {}"3" {}"" | --- text --- -| {}"" {}"4" {}""| +| {}"" {}"4" {}"" | --- text --- -| {}"Start with i=" {}"5" {}":"| +| {}"Start with i=" {}"5" {}":" | --- text --- -| {}"Loop not ran."| +| {}"Loop not ran." | --- return --- () --# saved #-- diff --git a/test/results/while loop.ans b/test/results/while loop.ans index 2c5885a..7364855 100644 --- a/test/results/while loop.ans +++ b/test/results/while loop.ans @@ -1,40 +1,40 @@ --# run #-- --- text --- -| {}"" {}"0" {}""| +| {}"" {}"0" {}"" | --- text --- -| {}"" {}"1" {}""| +| {}"" {}"1" {}"" | --- text --- -| {}"" {}"2" {}""| +| {}"" {}"2" {}"" | --- text --- -| {}"" {}"3" {}""| +| {}"" {}"3" {}"" | --- text --- -| {}"" {}"4" {}""| +| {}"" {}"4" {}"" | --- text --- -| {}"" {}"5" {}""| +| {}"" {}"5" {}"" | --- text --- -| {}"" {}"6" {}""| +| {}"" {}"6" {}"" | --- text --- -| {}"" {}"7" {}""| +| {}"" {}"7" {}"" | --- text --- -| {}"" {}"8" {}""| +| {}"" {}"8" {}"" | --- text --- -| {}"" {}"9" {}""| +| {}"" {}"9" {}"" | --- text --- -| {}"" {}"10" {}""| +| {}"" {}"10" {}"" | --- text --- -| {}"return in loop:"| +| {}"return in loop:" | --- text --- -| {}"" {}"0" {}""| +| {}"" {}"0" {}"" | --- text --- -| {}"" {}"1" {}""| +| {}"" {}"1" {}"" | --- text --- -| {}"" {}"2" {}""| +| {}"" {}"2" {}"" | --- text --- -| {}"" {}"3" {}""| +| {}"" {}"3" {}"" | --- text --- -| {}"" {}"4" {}""| +| {}"" {}"4" {}"" | --- text --- -| {}"" {}"5" {}""| +| {}"" {}"5" {}"" | --- return --- @() --# saved #--