public static void Main(string[] args) { object foo = new Foo(); NullRefTest containsnullref = new NullRefTest(); Struct s = new Struct(1); Outer(); GC.KeepAlive(foo); GC.KeepAlive(containsnullref); }