As in:
public class MyClass {
private static var MyProp = new {item1 = \"a\", item2 = \"b\"};
}
Note: The above doesn\'t compile nor wo
An property (or field) of a named class can't have an anonymous type, because such a type can't be referred to in code. However, an anonymous type can contain properties of anonymous type:
var myObj = new
{
Foo = new { Name = "Joe", Age = 20 }
};
But such a construct has no practical use outside the local scope...