private static void CheckTypeCanBeUsedInSignature(TypeDesc type) { DefType defType = type as DefType; if (defType != null) { defType.ComputeTypeContainsGCPointers(); if (defType.InstanceFieldSize.IsIndeterminate) { // // If a method's signature refers to a type with an indeterminate size, // the compilation will eventually fail when we generate the GCRefMap. // // Therefore we need to avoid adding these method into the graph // ThrowHelper.ThrowTypeLoadException(ExceptionStringID.ClassLoadGeneral, type); } } }