diff options
| author | Li Jin <dragon-fly@qq.com> | 2022-07-24 22:13:08 +0800 |
|---|---|---|
| committer | Li Jin <dragon-fly@qq.com> | 2022-07-24 22:13:08 +0800 |
| commit | 303834e1b1e6cd9cae64b66c2ae44dcd7185238f (patch) | |
| tree | 519f6a1debcc5791d35e06dc5cbb1ce22f9cfd31 /spec/outputs/syntax.lua | |
| parent | eb367126bf3a4f5b0e51ccef93b7c7136bea170e (diff) | |
| download | yuescript-303834e1b1e6cd9cae64b66c2ae44dcd7185238f.tar.gz yuescript-303834e1b1e6cd9cae64b66c2ae44dcd7185238f.tar.bz2 yuescript-303834e1b1e6cd9cae64b66c2ae44dcd7185238f.zip | |
add option --target=5.1 to generate Lua 5.1 compatible codes. add const destructure. make import item const by default.
Diffstat (limited to '')
| -rw-r--r-- | spec/outputs/syntax.lua | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/spec/outputs/syntax.lua b/spec/outputs/syntax.lua index 24b78c6..a4cb8e2 100644 --- a/spec/outputs/syntax.lua +++ b/spec/outputs/syntax.lua | |||
| @@ -56,10 +56,10 @@ something("else") | |||
| 56 | _ = something([[hey]]) * 2 | 56 | _ = something([[hey]]) * 2 |
| 57 | _ = something([======[hey]======]) * 2 | 57 | _ = something([======[hey]======]) * 2 |
| 58 | _ = something[ [======[hey]======]] * 2 | 58 | _ = something[ [======[hey]======]] * 2 |
| 59 | _ = something('else'), 2 | 59 | _, _ = something('else'), 2 |
| 60 | _ = something("else"), 2 | 60 | _, _ = something("else"), 2 |
| 61 | _ = something([[else]]), 2 | 61 | _, _ = something([[else]]), 2 |
| 62 | _ = something[ [[else]]], 2 | 62 | _, _ = something[ [[else]]], 2 |
| 63 | something('else', 2) | 63 | something('else', 2) |
| 64 | something("else", 2) | 64 | something("else", 2) |
| 65 | something([[else]], 2) | 65 | something([[else]], 2) |
| @@ -165,7 +165,7 @@ x = #{ | |||
| 165 | 2 | 165 | 2 |
| 166 | } | 166 | } |
| 167 | } | 167 | } |
| 168 | _ = hello, world | 168 | _, _ = hello, world |
| 169 | something:hello(what)(a, b) | 169 | something:hello(what)(a, b) |
| 170 | something:hello(what) | 170 | something:hello(what) |
| 171 | something.hello:world(a, b) | 171 | something.hello:world(a, b) |
