diff options
author | Marek Safar <marek.safar@gmail.com> | 2015-03-27 09:33:16 +0300 |
---|---|---|
committer | Marek Safar <marek.safar@gmail.com> | 2015-03-27 09:33:49 +0300 |
commit | b1f7fb3d763db197954a4e573fcee697d68a2cca (patch) | |
tree | a93da0751958bce141e993266da77df2cd936737 /mcs/tests/test-anon-176.cs | |
parent | 059538c11a961b0a08d834d09d1e46cc427ebd4c (diff) |
[mcs] Reset flowanalysis finally scope per parameters block. Fixes #28196
Diffstat (limited to 'mcs/tests/test-anon-176.cs')
-rw-r--r-- | mcs/tests/test-anon-176.cs | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/mcs/tests/test-anon-176.cs b/mcs/tests/test-anon-176.cs new file mode 100644 index 00000000000..aeeb66dd6e3 --- /dev/null +++ b/mcs/tests/test-anon-176.cs @@ -0,0 +1,36 @@ +using System; + +namespace TestDelegateFinallyOut +{ + class Test + { + static void CallDelegate (Action test) + { + throw new Exception ("test"); + } + + private static bool TestMethod (out int test) + { + try { + CallDelegate (delegate { + return; + }); + } catch (Exception) { + Console.WriteLine ("caught exception"); + } finally { + } + test = 1; + return false; + } + + static int Main () + { + int t; + TestMethod (out t); + if (t != 1) + return 1; + + return 0; + } + } +}
\ No newline at end of file |