28 references to GetEnumUnderlyingType
Microsoft.CodeAnalysis.CSharp (28)
Binder\Binder_Expressions.cs (1)
1525return ConstantValue.CreateSizeOf((type.GetEnumUnderlyingType() ?? type).SpecialType);
Binder\Binder_Operators.cs (2)
1726TypeSymbol underlyingType = enumType.GetEnumUnderlyingType()!; 2813var underlyingType = operand.Type.GetEnumUnderlyingType()!;
Binder\Semantics\Operators\BinaryOperatorOverloadResolution.cs (1)
474var underlying = enumType.GetEnumUnderlyingType();
CodeGen\EmitOperators.cs (3)
678SpecialType type = enumType.GetEnumUnderlyingType().SpecialType; 786return IsUnsigned(Binder.GetEnumPromotedType(op.Left.Type.GetEnumUnderlyingType().SpecialType)); 789return IsUnsigned(Binder.GetEnumPromotedType(op.Right.Type.GetEnumUnderlyingType().SpecialType));
Compilation\CSharpCompilation.cs (3)
4333csharpRightType.SpecialType == csharpLeftType.GetEnumUnderlyingType()?.SpecialType && 4340csharpLeftType.SpecialType == csharpRightType.GetEnumUnderlyingType()?.SpecialType && 4349csharpReturnType.SpecialType == csharpLeftType.GetEnumUnderlyingType()?.SpecialType &&
Lowering\ClosureConversion\ExpressionLambdaRewriter.cs (2)
510var promotedType = PromotedType(enumOperand.Type.StrippedType().GetEnumUnderlyingType()); 1188var promotedType = PromotedType(arg.Type.StrippedType().GetEnumUnderlyingType());
Lowering\LocalRewriter\LocalRewriter_Conversion.cs (8)
500var underlyingTypeFrom = rewrittenOperand.Type.GetEnumUnderlyingType()!; 511var underlyingTypeTo = rewrittenType.GetEnumUnderlyingType()!; 1115typeFromUnderlying = typeFrom.GetEnumUnderlyingType()!; 1123typeToUnderlying = typeTo.GetEnumUnderlyingType()!; 1543SpecialType t0Type = t0.IsEnumType() ? t0.GetEnumUnderlyingType()!.SpecialType : t0.SpecialType; 1544SpecialType s0Type = s0.IsEnumType() ? s0.GetEnumUnderlyingType()!.SpecialType : s0.SpecialType; 1820var underlying = toType.GetEnumUnderlyingType(); 1833var underlying = fromType.GetEnumUnderlyingType();
Lowering\LocalRewriter\LocalRewriter_UnaryOperator.cs (2)
132var underlyingType = loweredOperand.Type.GetEnumUnderlyingType(); 1025underlyingType = underlyingType.GetEnumUnderlyingType();
Symbols\Attributes\SourceAttributeData.cs (1)
310specType = parameterType.GetEnumUnderlyingType()!.SpecialType;
Symbols\BaseTypeAnalysis.cs (1)
249type = type.GetEnumUnderlyingType();
Symbols\Metadata\PE\SymbolFactory.cs (1)
56return type.GetEnumUnderlyingType();
Symbols\TypeSymbolExtensions.cs (3)
186return type.GetEnumUnderlyingType() ?? type; 227var underlyingType = type.GetEnumUnderlyingType(); 291type = type.GetEnumUnderlyingType()!;