There seems to be a problem in EnC impl of anonymous types in VB – in AssignTemplatesNamesAndCompile we never set the “key” flag of the field:
AnonymousTypeDescriptor.ComputeKey(key.Names, Function(f) f, Function(f) False)
Which then results in clashes – type (a, b) collides with (Key a, Key b), for example. My guess is we need to reconstruct the fact that a field is a “key” from metadata. This blocks EnC of almost all but trivial VB LINQ queries, because they heavily rely on anonymous types.
There seems to be a problem in EnC impl of anonymous types in VB – in AssignTemplatesNamesAndCompile we never set the “key” flag of the field:
AnonymousTypeDescriptor.ComputeKey(key.Names, Function(f) f, Function(f) False)Which then results in clashes – type (a, b) collides with (Key a, Key b), for example. My guess is we need to reconstruct the fact that a field is a “key” from metadata. This blocks EnC of almost all but trivial VB LINQ queries, because they heavily rely on anonymous types.