diff options
author | Li Jin <dragon-fly@qq.com> | 2024-03-21 09:14:34 +0800 |
---|---|---|
committer | Li Jin <dragon-fly@qq.com> | 2024-03-21 09:14:34 +0800 |
commit | 4a3cc26c6dfd74e61c8b6480038d6a292ea86e47 (patch) | |
tree | 9554b94cfc15e4acee0c2e60b63af16f1b828207 /spec/outputs/stub.lua | |
parent | 80b65520da432843f0c63431a1867bd2620bc4ac (diff) | |
download | yuescript-4a3cc26c6dfd74e61c8b6480038d6a292ea86e47.tar.gz yuescript-4a3cc26c6dfd74e61c8b6480038d6a292ea86e47.tar.bz2 yuescript-4a3cc26c6dfd74e61c8b6480038d6a292ea86e47.zip |
remove redundant 'do' blocks in code generation.
Diffstat (limited to 'spec/outputs/stub.lua')
-rw-r--r-- | spec/outputs/stub.lua | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/spec/outputs/stub.lua b/spec/outputs/stub.lua index ff867ba..a3a27e3 100644 --- a/spec/outputs/stub.lua +++ b/spec/outputs/stub.lua | |||
@@ -15,12 +15,10 @@ end | |||
15 | print(fn()) | 15 | print(fn()) |
16 | print(x:val()); | 16 | print(x:val()); |
17 | (function(...) | 17 | (function(...) |
18 | do | 18 | local _base_0 = hello(...) |
19 | local _base_0 = hello(...) | 19 | local _fn_0 = _base_0.world |
20 | local _fn_0 = _base_0.world | 20 | x = _fn_0 and function(...) |
21 | x = _fn_0 and function(...) | 21 | return _fn_0(_base_0, ...) |
22 | return _fn_0(_base_0, ...) | ||
23 | end | ||
24 | end | 22 | end |
25 | end)() | 23 | end)() |
26 | return nil | 24 | return nil |