27 references to ObjectCreation
Microsoft.CodeAnalysis.CSharp (7)
Binder\Semantics\Conversions\Conversion.cs (2)
274
internal static Conversion ObjectCreation => new Conversion(ConversionKind.
ObjectCreation
);
708
return Kind == ConversionKind.
ObjectCreation
;
Binder\Semantics\Conversions\ConversionKindExtensions.cs (1)
53
case
ObjectCreation
:
FlowAnalysis\NullableWalker.cs (2)
2179
case ConversionKind.ConditionalExpression or ConversionKind.SwitchExpression or ConversionKind.
ObjectCreation
when
9536
case ConversionKind.
ObjectCreation
:
Lowering\LocalRewriter\LocalRewriter_Conversion.cs (1)
45
case ConversionKind.
ObjectCreation
:
Lowering\LocalRewriter\LocalRewriter_TupleBinaryOperator.cs (1)
237
case ConversionKind.
ObjectCreation
:
Microsoft.CodeAnalysis.CSharp.Semantic.UnitTests (20)
Semantics\ImplicitObjectCreationTests.cs (20)
53
assert(0, type: "C", convertedType: "C", symbol: "C..ctor()", ConversionKind.
ObjectCreation
);
54
assert(1, type: "S", convertedType: "S", symbol: "S..ctor()", ConversionKind.
ObjectCreation
);
55
assert(2, type: "S", convertedType: "S?", symbol: "S..ctor()", ConversionKind.
ObjectCreation
);
128
assert(0, type: "C", convertedType: "C", symbol: "C..ctor()", ConversionKind.
ObjectCreation
);
129
assert(1, type: "S", convertedType: "S", symbol: "S..ctor()", ConversionKind.
ObjectCreation
);
130
assert(2, type: "S", convertedType: "S?", symbol: "S..ctor()", ConversionKind.
ObjectCreation
);
175
assert(0, type: "C", convertedType: "C", symbol: "C..ctor()", ConversionKind.
ObjectCreation
);
176
assert(1, type: "S", convertedType: "S", symbol: "S..ctor()", ConversionKind.
ObjectCreation
);
177
assert(2, type: "S", convertedType: "S?", symbol: "S..ctor()", ConversionKind.
ObjectCreation
);
225
assert(0, type: "C", convertedType: "C", symbol: "C..ctor()", constant: null, ConversionKind.
ObjectCreation
);
226
assert(1, type: "S", convertedType: "S", symbol: "S..ctor()", constant: null, ConversionKind.
ObjectCreation
);
227
assert(2, type: "S", convertedType: "S?", symbol: "S..ctor()", constant: null, ConversionKind.
ObjectCreation
);
228
assert(3, type: "System.Int32", convertedType: "System.Int32", symbol: "System.Int32..ctor()", constant: "0", ConversionKind.
ObjectCreation
);
229
assert(4, type: "System.Boolean", convertedType: "System.Boolean?", symbol: "System.Boolean..ctor()", constant: "False", ConversionKind.
ObjectCreation
);
843
Assert.Equal(ConversionKind.
ObjectCreation
, model.GetConversion(@new).Kind);
884
Assert.Equal(ConversionKind.
ObjectCreation
, model.GetConversion(@new).Kind);
2915
assert(0, type: "System.Index", convertedType: "System.Index", symbol: "System.Index..ctor()", ConversionKind.
ObjectCreation
);
2916
assert(1, type: "System.Index", convertedType: "System.Index", symbol: "System.Index..ctor()", ConversionKind.
ObjectCreation
);
2917
assert(2, type: "System.Index", convertedType: "System.Index", symbol: "System.Index..ctor()", ConversionKind.
ObjectCreation
);
2918
assert(3, type: "System.Index", convertedType: "System.Index", symbol: "System.Index..ctor()", ConversionKind.
ObjectCreation
);