[mono/tests] Fix out of tree build.
[mono-project.git] / mcs / tests / dtest-038.cs
blobe6f747bde8bd18de6d3443725522be6f186b1b21
1 using System;
2 using Microsoft.CSharp.RuntimeBinder;
4 public class Test
6 void Foo ()
10 public static int Main ()
12 dynamic d = new Test ();
14 var t1 = true ? d : 2;
15 t1.Foo ();
17 var t2 = true ? 1 : d;
18 if (t2 != 1)
19 return 1;
21 try {
22 t2.Foo ();
23 return 2;
24 } catch (RuntimeBinderException) {
27 return 0;