diff options
Diffstat (limited to 'tests/accept/run/tfinally3.nim')
-rw-r--r-- | tests/accept/run/tfinally3.nim | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/tests/accept/run/tfinally3.nim b/tests/accept/run/tfinally3.nim new file mode 100644 index 000000000..e8d81c893 --- /dev/null +++ b/tests/accept/run/tfinally3.nim @@ -0,0 +1,12 @@ +# Test break in try statement: + +proc main: bool = + while true: + try: + return true + finally: + break + return false + +echo main() #OUT false + |