/// <summary> /// Creates a method symbol that can be used to describe a conversion declaration. /// </summary> public static IMethodSymbol CreateConversionSymbol(IList <AttributeData> attributes, Accessibility accessibility, SymbolModifiers modifiers, ITypeSymbol toType, IParameterSymbol fromType, bool isImplicit = false, IList <SyntaxNode> statements = null, IList <AttributeData> toTypeAttributes = null) { var result = new CodeGenerationConversionSymbol(null, attributes, accessibility, modifiers, toType, fromType, isImplicit, toTypeAttributes); CodeGenerationMethodInfo.Attach(result, modifiers.IsNew, modifiers.IsUnsafe, modifiers.IsPartial, modifiers.IsAsync, statements, handlesExpressions: null); return(result); }
/// <summary> /// Creates a method symbol that can be used to describe a conversion declaration. /// </summary> public static IMethodSymbol CreateConversionSymbol(IList<AttributeData> attributes, Accessibility accessibility, DeclarationModifiers modifiers, ITypeSymbol toType, IParameterSymbol fromType, bool isImplicit = false, IList<SyntaxNode> statements = null, IList<AttributeData> toTypeAttributes = null) { var result = new CodeGenerationConversionSymbol(null, attributes, accessibility, modifiers, toType, fromType, isImplicit, toTypeAttributes); CodeGenerationMethodInfo.Attach(result, modifiers.IsNew, modifiers.IsUnsafe, modifiers.IsPartial, modifiers.IsAsync, statements, handlesExpressions: null); return result; }