New test.
[mono.git] / mcs / errors / cs0165-11.cs
1 // cs0165-11.cs: Use of unassigned local variable `fb'
2 // Line: 12
3 using System.Collections;
4
5 public class EntryPoint {
6   public static void Main() {
7     ArrayList fields = new ArrayList();
8
9     Field fb;
10     while (fields.Count > 0) {
11       fb = (Field) fields[0];
12     }
13
14     if (fb.Name != "b") {
15       System.Console.WriteLine ("shouldn't compile here.");
16     }
17   }
18
19   public class Field
20   {
21     public string Name;
22   }
23 }
24