diff options
| author | Bruce Hill <bruce@bruce-hill.com> | 2018-12-30 23:58:47 -0800 |
|---|---|---|
| committer | Bruce Hill <bruce@bruce-hill.com> | 2018-12-30 23:58:47 -0800 |
| commit | 5059c081ac624ede925d5256885509ddd17181c6 (patch) | |
| tree | 0457d135e5193126bf73466bfaae09df94ab8a7d /compatibility/2.4.nom | |
| parent | ec69ee6f62016a2edcc13e3183cbe4cadd75717f (diff) | |
Auto-upgraded code.
Diffstat (limited to 'compatibility/2.4.nom')
| -rw-r--r-- | compatibility/2.4.nom | 15 |
1 files changed, 10 insertions, 5 deletions
diff --git a/compatibility/2.4.nom b/compatibility/2.4.nom index 1279968..40b363a 100644 --- a/compatibility/2.4.nom +++ b/compatibility/2.4.nom @@ -37,12 +37,15 @@ upgrade $tree to "2.4" as: $action = (=lua "SyntaxTree{type='Block', source=\$action.source, \$action}") $conditions, add $action $new_lines, add - =lua "SyntaxTree{type='Action', source=\$conditions[1].source, unpack(\$conditions)}" + =lua (" + SyntaxTree{type='Action', source=\$conditions[1].source, unpack(\$conditions)} + ") $conditions = [] return \(when $body) with vars { - .body = (=lua "SyntaxTree{type='Block', source=\$tree[2].source, unpack(\$new_lines)}") + .body = + =lua "SyntaxTree{type='Block', source=\$tree[2].source, unpack(\$new_lines)}" } "if 1 is ?" "if 1 = ?": @@ -70,11 +73,13 @@ upgrade $tree to "2.4" as: $action = $line.3 unless ($action is "Block" syntax tree): $action = \(: $action) $values, add $action - $new_lines, - add (=lua "SyntaxTree{type='Action', source=\$values[1].source, unpack(\$values)}") + $new_lines, add + =lua "SyntaxTree{type='Action', source=\$values[1].source, unpack(\$values)}" $values = [] return \(if $var is $body) with vars { - .var = ($tree.2 upgraded), .body = (=lua "SyntaxTree{type='Block', source=\$tree[5].source, unpack(\$new_lines)}") + .var = ($tree.2 upgraded) + .body = + =lua "SyntaxTree{type='Block', source=\$tree[5].source, unpack(\$new_lines)}" } |
