60 references to Type
Microsoft.CodeAnalysis.CSharp (60)
Binder\Binder.ValueChecks.cs (1)
5522
return GetInlineArrayConversionEquivalentSignatureMethod(inlineArray: conversion.Operand, resultType: conversion.
Type
, out arguments, out refKinds);
Binder\Binder_Attributes.cs (1)
910
var type = node.
Type
;
Binder\Binder_Operators.cs (1)
69
explicitCastInCode: true, conversion.ConstantValueOpt, conversion.ConversionGroupOpt, conversion.
Type
);
BoundTree\BoundExpression.cs (1)
480
return this.Update(operand: operand, this.Conversion, this.IsBaseConversion, this.Checked, this.ExplicitCastInCode, this.ConstantValueOpt, this.ConversionGroupOpt, this.OriginalUserDefinedConversionsOpt, this.
Type
);
CodeGen\EmitConversion.cs (11)
142
var toType = conversion.
Type
;
192
switch (conversion.
Type
.PrimitiveTypeCode)
218
var toType = conversion.
Type
;
239
var resultType = conversion.
Type
;
243
EmitSymbolToken(conversion.
Type
, conversion.Syntax);
251
EmitStaticCast(conversion.
Type
, conversion.Syntax);
272
if (conversion.
Type
.IsVerifierReference())
275
EmitSymbolToken(conversion.
Type
, conversion.Syntax);
280
EmitSymbolToken(conversion.
Type
, conversion.Syntax);
288
Debug.Assert(!conversion.
Type
.IsNullableType());
299
var toType = conversion.
Type
;
CodeGen\EmitOperators.cs (1)
375
if (comparand is BoundConversion {
Type
.SpecialType: SpecialType.System_Object, ConversionKind: ConversionKind.Boxing, Operand.Type: TypeParameterSymbol { AllowsRefLikeType: true } } &&
Compilation\CSharpSemanticModel.cs (1)
2242
else if (boundExpr is BoundConversion { ConversionKind: ConversionKind.MethodGroup, Conversion: var exprConversion,
Type
: { TypeKind: TypeKind.FunctionPointer }, SymbolOpt: var symbol })
FlowAnalysis\DefiniteAssignment.cs (1)
2808
node.
Type
.OriginalDefinition.Equals(compilation.GetWellKnownType(WellKnownType.System_Span_T), TypeCompareKind.AllIgnoreOptions))
FlowAnalysis\NullableWalker.cs (4)
2042
var convertedType = conv.
Type
;
2059
TypeSymbol.Equals(conv.
Type
, conv.Operand.Type, TypeCompareKind.IgnoreNullableModifiersForReferenceTypes):
5697
TypeWithAnnotations targetType = fromExplicitCast ? explicitType : TypeWithAnnotations.Create(boundConversion.
Type
);
8272
TypeWithAnnotations targetType = fromExplicitCast ? explicitType : TypeWithAnnotations.Create(node.
Type
);
Generated\BoundNodes.xml.Generated.cs (4)
2983
if (operand != this.Operand || conversion != this.Conversion || isBaseConversion != this.IsBaseConversion || @checked != this.Checked || explicitCastInCode != this.ExplicitCastInCode || constantValueOpt != this.ConstantValueOpt || conversionGroupOpt != this.ConversionGroupOpt || originalUserDefinedConversionsOpt != this.OriginalUserDefinedConversionsOpt || !TypeSymbol.Equals(type, this.
Type
, TypeCompareKind.ConsiderEverything))
11241
TypeSymbol? type = this.VisitType(node.
Type
);
13278
updatedNode = node.Update(operand, node.Conversion, node.IsBaseConversion, node.Checked, node.ExplicitCastInCode, node.ConstantValueOpt, node.ConversionGroupOpt, node.OriginalUserDefinedConversionsOpt, node.
Type
);
15633
new TreeDumperNode("type", node.
Type
, null),
Lowering\ClosureConversion\ClosureConversion.cs (1)
1410
type: conversion.
Type
);
Lowering\ClosureConversion\ExpressionLambdaRewriter.cs (11)
539
conversion.
Type
.StrippedType().IsEnumType())
680
type: conversion.
Type
);
693
return DelegateCreation(mg.ReceiverOpt, node.SymbolOpt, node.
Type
, !node.SymbolOpt.RequiresInstanceReceiver && !node.IsExtensionMethod);
706
var resultType = (isLifted && method.ReturnType.IsNonNullableValueType() && node.
Type
.IsNullableType()) ?
716
return Convert(e2, resultType, node.
Type
, node.Checked, false);
722
return node.ExplicitCastInCode ? Convert(operand, node.
Type
, false) : operand;
727
return Convert(Visit(node.Operand), node.Operand.Type, node.
Type
, node.Checked, node.ExplicitCastInCode);
732
var nullable = (NamedTypeSymbol)node.
Type
;
735
return Convert(e1, intermediate, node.
Type
, node.Checked, false);
738
return Convert(Constant(_bound.Null(_objectType)), _objectType, node.
Type
, false, node.ExplicitCastInCode);
740
return Convert(Visit(node.Operand), node.Operand.Type, node.
Type
, node.Checked, node.ExplicitCastInCode);
Lowering\DiagnosticsPass_ExpressionTrees.cs (2)
791
CheckMethodGroup((BoundMethodGroup)node.Operand, node.Conversion.Method, node.IsExtensionMethod, parentIsConversion: true, node.
Type
);
796
if (!wasInExpressionLambda && node.
Type
.IsExpressionTree())
Lowering\DiagnosticsPass_Warnings.cs (2)
447
if (!conversion.Operand.Type.SpecialType.IsIntegralType() || !conversion.
Type
.SpecialType.IsIntegralType())
613
TypeSymbol to = conv.
Type
;
Lowering\LocalRewriter\LocalRewriter.cs (1)
1117
return expr is BoundConversion { Conversion: { IsInterpolatedStringHandler: true },
Type
: { IsValueType: true } };
Lowering\LocalRewriter\LocalRewriter_Conversion.cs (8)
25
Debug.Assert(node.
Type
is NamedTypeSymbol { IsInterpolatedStringHandlerType: true });
50
if (node.
Type
.IsNullableType())
53
return ConvertToNullable(node.Syntax, node.
Type
, objectCreation);
63
return ConvertToNullable(node.Syntax, node.
Type
, rewrittenCollection);
69
var rewrittenType = VisitType(node.
Type
);
81
var toType = node.
Type
;
550
case ConversionKind.MethodGroup when oldNodeOpt is {
Type
: { TypeKind: TypeKind.FunctionPointer } funcPtrType }:
1024
type: conversion.
Type
.StrippedType(),
Lowering\LocalRewriter\LocalRewriter_TupleBinaryOperator.cs (3)
63
var resultTypes = conversion.
Type
.TupleElementTypesWithAnnotations;
85
ImmutableArray<bool>.Empty, conversion.
Type
, conversion.HasErrors);
612
constantValueOpt: conv.ConstantValueOpt, rewrittenType: conv.
Type
)
Lowering\MethodToClassRewriter.cs (1)
308
VisitType(node.
Type
));
Lowering\SpillSequenceSpiller.cs (1)
1176
if (node.ConversionKind == ConversionKind.AnonymousFunction && node.
Type
.IsExpressionTree())
Operations\CSharpOperationFactory.cs (4)
1034
if (boundConversion.
Type
is FunctionPointerTypeSymbol)
1082
if (boundOperand.Kind == BoundKind.ConvertedTupleLiteral && TypeSymbol.Equals(boundOperand.Type, boundConversion.
Type
, TypeCompareKind.ConsiderEverything2))
1103
!TypeSymbol.Equals(nestedConversion.
Type
, nestedOperand.Type, TypeCompareKind.ConsiderEverything2))
1121
boundConversion.
Type
.IsDelegateType())