public enum LanguageVersion
{
Default = 0,
- ISO_1 = 1
+ ISO_1 = 1,
+ LINQ
}
public class RootContext {
//
// Resolves a single class during the corlib bootstrap process
//
- static TypeBuilder BootstrapCorlib_ResolveClass (TypeContainer root, string name)
+ static Type BootstrapCorlib_ResolveClass (TypeContainer root, string name)
{
object o = root.GetDefinition (name);
if (o == null){
return null;
}
- return ((DeclSpace) o).DefineType ();
+ Type t = ((DeclSpace) o).DefineType ();
+ if (t != null)
+ AttributeTester.RegisterNonObsoleteType (t);
+ return t;
}
//
return;
}
- ((DeclSpace) o).DefineType ();
+ Type t = ((DeclSpace) o).DefineType ();
+ if (t != null)
+ AttributeTester.RegisterNonObsoleteType (t);
}
//
TypeManager.system_object_expr.Type = TypeManager.object_type;
TypeManager.value_type = BootstrapCorlib_ResolveClass (root, "System.ValueType");
TypeManager.system_valuetype_expr.Type = TypeManager.value_type;
+
+ //
+ // The core attributes
+ //
+ BootstrapCorlib_ResolveInterface (root, "System.Runtime.InteropServices._Attribute");
TypeManager.attribute_type = BootstrapCorlib_ResolveClass (root, "System.Attribute");
+ TypeManager.obsolete_attribute_type = BootstrapCorlib_ResolveClass (root, "System.ObsoleteAttribute");
TypeManager.indexer_name_type = BootstrapCorlib_ResolveClass (root, "System.Runtime.CompilerServices.IndexerNameAttribute");
string [] interfaces_first_stage = {
"System.Runtime.CompilerServices.FixedBufferAttribute",
#endif
"System.Diagnostics.ConditionalAttribute",
- "System.ObsoleteAttribute",
"System.ParamArrayAttribute",
"System.CLSCompliantAttribute",
"System.Security.UnverifiableCodeAttribute",