From e10b1b163a9a173f32b956bf1fb9be00194352b5 Mon Sep 17 00:00:00 2001 From: Li Jin Date: Sun, 29 Jan 2023 10:29:19 +0800 Subject: fix cases from issue #120. --- spec/inputs/loops.yue | 6 ++++-- spec/inputs/return.yue | 2 +- 2 files changed, 5 insertions(+), 3 deletions(-) (limited to 'spec/inputs') diff --git a/spec/inputs/loops.yue b/spec/inputs/loops.yue index d997c65..51eb10b 100644 --- a/spec/inputs/loops.yue +++ b/spec/inputs/loops.yue @@ -75,15 +75,17 @@ while also do i = 0 x = while i < 10 i += 1 + i --- values that can'e be coerced +-- values that can't be coerced x = for thing in *3 y = "hello" + break x = for x=1,2 y = "hello" - + y -- continue diff --git a/spec/inputs/return.yue b/spec/inputs/return.yue index 96fa0cd..fda8d62 100644 --- a/spec/inputs/return.yue +++ b/spec/inputs/return.yue @@ -6,7 +6,7 @@ _ = -> [x for x in *things] -- doesn't make sense on purpose do - return x for x in *things + for x in *things do return x do return [x for x in *things] -- cgit v1.2.3-55-g6feb