diff options
| author | Li Jin <dragon-fly@qq.com> | 2020-01-25 17:48:03 +0800 |
|---|---|---|
| committer | Li Jin <dragon-fly@qq.com> | 2020-01-25 17:48:03 +0800 |
| commit | ed317e62eb1cf98fde4461fc90c6cb1045ebc7e8 (patch) | |
| tree | 427e365939da39f31dbfa755675fb60bb141583d /spec/inputs/operators.moon | |
| parent | 4827d200604a086e2ad94edb4257c3abc7a3c4fc (diff) | |
| download | yuescript-ed317e62eb1cf98fde4461fc90c6cb1045ebc7e8.tar.gz yuescript-ed317e62eb1cf98fde4461fc90c6cb1045ebc7e8.tar.bz2 yuescript-ed317e62eb1cf98fde4461fc90c6cb1045ebc7e8.zip | |
fix Moonscript issue 375.
Diffstat (limited to 'spec/inputs/operators.moon')
| -rw-r--r-- | spec/inputs/operators.moon | 54 |
1 files changed, 27 insertions, 27 deletions
diff --git a/spec/inputs/operators.moon b/spec/inputs/operators.moon index 142ef62..57e58d6 100644 --- a/spec/inputs/operators.moon +++ b/spec/inputs/operators.moon | |||
| @@ -3,70 +3,70 @@ | |||
| 3 | x = 1 + 3 | 3 | x = 1 + 3 |
| 4 | 4 | ||
| 5 | y = 1 + | 5 | y = 1 + |
| 6 | 3 | 6 | 3 |
| 7 | 7 | ||
| 8 | z = 1 + | 8 | z = 1 + |
| 9 | 3 + | 9 | 3 + |
| 10 | 4 | 10 | 4 |
| 11 | 11 | ||
| 12 | -- | 12 | -- |
| 13 | 13 | ||
| 14 | k = b and c and | 14 | k = b and c and |
| 15 | g | 15 | g |
| 16 | 16 | ||
| 17 | 17 | ||
| 18 | h = thing and | 18 | h = thing and |
| 19 | -> | 19 | -> |
| 20 | print "hello world" | 20 | print "hello world" |
| 21 | 21 | ||
| 22 | -- TODO: should fail, indent still set to previous line so it thinks body is | 22 | -- TODO: should fail, indent still set to previous line so it thinks body is |
| 23 | -- indented | 23 | -- indented |
| 24 | i = thing or | 24 | i = thing or |
| 25 | -> | 25 | -> |
| 26 | print "hello world" | 26 | print "hello world" |
| 27 | 27 | ||
| 28 | p = thing and | 28 | p = thing and |
| 29 | -> | 29 | -> |
| 30 | print "hello world" | 30 | print "hello world" |
| 31 | 31 | ||
| 32 | s = thing or | 32 | s = thing or |
| 33 | -> and 234 | 33 | -> and 234 |
| 34 | 34 | ||
| 35 | 35 | ||
| 36 | -- | 36 | -- |
| 37 | u = { | 37 | u = { |
| 38 | color: 1 and 2 and | 38 | color: 1 and 2 and |
| 39 | 3 | 39 | 3 |
| 40 | 4 | 40 | 4 |
| 41 | 4 | 41 | 4 |
| 42 | } | 42 | } |
| 43 | 43 | ||
| 44 | v = { | 44 | v = { |
| 45 | color: 1 and | 45 | color: 1 and |
| 46 | -> | 46 | -> |
| 47 | "yeah" | 47 | "yeah" |
| 48 | "great" | 48 | "great" |
| 49 | oksy: 3 ^ | 49 | oksy: 3 ^ |
| 50 | 2 | 50 | 2 |
| 51 | } | 51 | } |
| 52 | 52 | ||
| 53 | -- parens | 53 | -- parens |
| 54 | 54 | ||
| 55 | nno = ( | 55 | nno = ( |
| 56 | yeah + 2 ) | 56 | yeah + 2 ) |
| 57 | 57 | ||
| 58 | nn = ( | 58 | nn = ( |
| 59 | yeah + 2 | 59 | yeah + 2 |
| 60 | ) | 60 | ) |
| 61 | 61 | ||
| 62 | n = hello( | 62 | n = hello( |
| 63 | b | 63 | b |
| 64 | ) -> | 64 | ) -> |
| 65 | 65 | ||
| 66 | hello a, | 66 | hello a, |
| 67 | ( | 67 | ( |
| 68 | yeah + | 68 | yeah + |
| 69 | 2 | 69 | 2 |
| 70 | ) - | 70 | ) - |
| 71 | okay | 71 | okay |
| 72 | 72 | ||
