[jit] Fix the saving of the 'cfg->ret_var_set' flag when inlining, it was set to...
[mono.git] / samples / embed / invoke.cs
1 using System;
2
3 namespace Embed {
4         class MyType {
5                 int val = 5;
6                 string str = "hello";
7
8                 MyType () {
9                         Console.WriteLine ("In ctor val is: {0}", val);
10                         Console.WriteLine ("In ctor str is: {0}", str);
11                 }
12                 
13                 MyType (int v, byte[] array) {
14                         Console.WriteLine ("In ctor (int, byte[]) got value: {0}, array len: {1}", v, array.Length);
15                 }
16
17                 void method () {
18                         Console.WriteLine ("In method val is {0}", val);
19                         Console.WriteLine ("In method str is: {0}", str);
20                 }
21
22                 int Value {
23                         get {
24                                 return val;
25                         }
26                 }
27
28                 string Message {
29                         get {
30                                 return str;
31                         }
32                 }
33
34                 void Values (ref int v, ref string s) {
35                         Console.WriteLine ("In Values () v is {0}", v);
36                         Console.WriteLine ("In Values () s is: {0}", s);
37                         v = val;
38                         s = str;
39                 }
40
41                 static void Fail () {
42                         throw new Exception ();
43                 }
44                 
45                 static void Main () {
46                         /* we do nothing here... */
47                 }
48         }
49 }
50