diff options
Diffstat (limited to 'test/prism/fixtures/if.txt')
-rw-r--r-- | test/prism/fixtures/if.txt | 42 |
1 files changed, 42 insertions, 0 deletions
diff --git a/test/prism/fixtures/if.txt b/test/prism/fixtures/if.txt new file mode 100644 index 0000000000..4139bae5ed --- /dev/null +++ b/test/prism/fixtures/if.txt @@ -0,0 +1,42 @@ +if true; 1; end + +if true +1 else 2 end + +if true then true elsif false then false elsif nil then nil else self end + +1 if true + +tap { break if true } + +tap { next if true } + +return if true + +tap { if exit_loop then break 42 end } + +if foo +then bar +end + +a if b if c + +if true + a b: +else +end + +if type in 1 +elsif type in B +end + +if f1 + lambda do |_| + end +elsif f2 + lambda do |_| + end +else + lambda do |_| + end +end |