// Initializes a substitution context. Returns false iff no substitutions will ever be performed. private void Init(TypeArray typeArgsCls, TypeArray typeArgsMeth, SubstTypeFlags grfst) { if (typeArgsCls != null) { typeArgsCls.AssertValid(); ctypeCls = typeArgsCls.Count; prgtypeCls = typeArgsCls.Items; } else { ctypeCls = 0; prgtypeCls = null; } if (typeArgsMeth != null) { typeArgsMeth.AssertValid(); ctypeMeth = typeArgsMeth.Count; prgtypeMeth = typeArgsMeth.Items; } else { ctypeMeth = 0; prgtypeMeth = null; } this.grfst = grfst; }
// Initializes a substitution context. Returns false iff no substitutions will ever be performed. public void Init(TypeArray typeArgsCls, TypeArray typeArgsMeth, SubstTypeFlags grfst) { if (typeArgsCls != null) { #if DEBUG typeArgsCls.AssertValid(); #endif ctypeCls = typeArgsCls.size; prgtypeCls = typeArgsCls.ToArray(); } else { ctypeCls = 0; prgtypeCls = null; } if (typeArgsMeth != null) { #if DEBUG typeArgsMeth.AssertValid(); #endif ctypeMeth = typeArgsMeth.size; prgtypeMeth = typeArgsMeth.ToArray(); } else { ctypeMeth = 0; prgtypeMeth = null; } this.grfst = grfst; }
// Initializes a substitution context. Returns false iff no substitutions will ever be performed. private void Init(TypeArray typeArgsCls, TypeArray typeArgsMeth, SubstTypeFlags grfst) { if (typeArgsCls != null) { #if DEBUG typeArgsCls.AssertValid(); #endif ctypeCls = typeArgsCls.size; prgtypeCls = typeArgsCls.ToArray(); } else { ctypeCls = 0; prgtypeCls = null; } if (typeArgsMeth != null) { #if DEBUG typeArgsMeth.AssertValid(); #endif ctypeMeth = typeArgsMeth.size; prgtypeMeth = typeArgsMeth.ToArray(); } else { ctypeMeth = 0; prgtypeMeth = null; } this.grfst = grfst; }
public SubstContext(TypeArray typeArgsCls, TypeArray typeArgsMeth, bool denormMeth) { typeArgsCls?.AssertValid(); ClassTypes = typeArgsCls?.Items ?? Array.Empty <CType>(); typeArgsMeth?.AssertValid(); MethodTypes = typeArgsMeth?.Items ?? Array.Empty <CType>(); DenormMeth = denormMeth; }