[amd64] Save missing register
[mono.git] / mcs / errors / cs0027-2.cs
1 // CS0027: Keyword `this' is not available in the current context
2 // Line: 10
3
4 // Attention: Here the compiler complains saying that cannot convert implicitly from 'Error0027' to 'int' but
5 // should also say that the use of keyword 'this' is out of context since it's used outside a constructor, method
6 // or property.
7 using System;
8
9 class Error0027 {
10         int i = this;
11         int x = 0;
12         
13         public static void Main () {
14                 Console.WriteLine ("The compiler should complain: Error CS0027 trying to use 'this' outside context.");
15                 Console.WriteLine ("Trying to assign i to 'this' outside a method, property or ctr.");
16         }
17 }
18