24 overrides of RefKind
Microsoft.CodeAnalysis.CSharp (24)
Lowering\IteratorRewriter\IteratorFinallyMethodSymbol.cs (1)
140
public override RefKind
RefKind
Symbols\AnonymousTypes\SynthesizedSymbols\AnonymousType.ConstructorSymbol.cs (1)
53
public override RefKind
RefKind
Symbols\AnonymousTypes\SynthesizedSymbols\AnonymousType.EqualsMethodSymbol.cs (1)
38
public override RefKind
RefKind
Symbols\AnonymousTypes\SynthesizedSymbols\AnonymousType.GetHashCodeMethodSymbol.cs (1)
42
public override RefKind
RefKind
Symbols\AnonymousTypes\SynthesizedSymbols\AnonymousType.PropertyAccessorSymbol.cs (1)
39
public override RefKind
RefKind
Symbols\AnonymousTypes\SynthesizedSymbols\AnonymousType.ToStringMethodSymbol.cs (1)
42
public override RefKind
RefKind
Symbols\ErrorMethodSymbol.cs (1)
158
public override RefKind
RefKind
Symbols\FunctionPointers\FunctionPointerMethodSymbol.cs (1)
767
public override RefKind
RefKind
{ get; }
Symbols\Metadata\PE\PEMethodSymbol.cs (1)
662
public override RefKind
RefKind
=> Signature.ReturnParam.RefKind;
Symbols\ReducedExtensionMethodSymbol.cs (1)
487
public override RefKind
RefKind
Symbols\SignatureOnlyMethodSymbol.cs (1)
75
public override RefKind
RefKind
{ get { return _refKind; } }
Symbols\Source\LambdaSymbol.cs (1)
145
public override RefKind
RefKind
Symbols\Source\LocalFunctionSymbol.cs (1)
237
public override RefKind
RefKind
=> _refKind;
Symbols\Source\SourceMemberMethodSymbol.cs (1)
1127
public sealed override RefKind
RefKind
=> this.flags.RefKind;
Symbols\Synthesized\SynthesizedDelegateSymbol.cs (1)
163
public override RefKind
RefKind
{ get; }
Symbols\Synthesized\SynthesizedEntryPointSymbol.cs (1)
115
public override RefKind
RefKind
Symbols\Synthesized\SynthesizedGlobalMethodSymbol.cs (1)
204
public override RefKind
RefKind
Symbols\Synthesized\SynthesizedImplementationMethod.cs (1)
96
public sealed override RefKind
RefKind
Symbols\Synthesized\SynthesizedInstanceConstructor.cs (1)
149
public override RefKind
RefKind
Symbols\Synthesized\SynthesizedInteractiveInitializerMethod.cs (1)
114
public override RefKind
RefKind
Symbols\Synthesized\SynthesizedIntrinsicOperatorSymbol.cs (1)
216
public override RefKind
RefKind
Symbols\Synthesized\SynthesizedSealedPropertyAccessor.cs (1)
181
public override RefKind
RefKind
Symbols\Synthesized\SynthesizedStaticConstructor.cs (1)
127
public override RefKind
RefKind
Symbols\Wrapped\WrappedMethodSymbol.cs (1)
56
public override RefKind
RefKind
87 references to RefKind
Microsoft.CodeAnalysis.CSharp (87)
Binder\Binder.ValueChecks.cs (18)
53
Method is {
RefKind
: not RefKind.None, ReturnType: { } returnType } &&
1668
if (RequiresVariable(valueKind) && methodSymbol.
RefKind
== RefKind.None)
1683
if (RequiresAssignableVariable(valueKind) && methodSymbol.
RefKind
== RefKind.RefReadOnly)
3446
if (methodSymbol.
RefKind
== RefKind.None)
3529
if (methodSymbol.
RefKind
== RefKind.None)
3608
conversion.Conversion.Method.
RefKind
== RefKind.None));
3615
unaryMethod.
RefKind
== RefKind.None));
3622
binaryMethod.
RefKind
== RefKind.None));
3628
logicalOperator.LogicalOperator.
RefKind
== RefKind.None));
3635
compoundMethod.
RefKind
== RefKind.None));
3763
if (methodSymbol.
RefKind
== RefKind.None)
3846
if (methodSymbol.
RefKind
== RefKind.None)
3978
conversion.Conversion.Method.
RefKind
== RefKind.None);
3985
unaryMethod.
RefKind
== RefKind.None));
3992
binaryMethod.
RefKind
== RefKind.None));
3998
logicalOperator.LogicalOperator.
RefKind
== RefKind.None));
4005
compoundMethod.
RefKind
== RefKind.None));
5772
var methodRefKind = ((BoundCall)expression).Method.
RefKind
;
Binder\Binder_Conversions.cs (5)
2880
if (delegateOrFuncPtrMethod.
RefKind
!= method.
RefKind
)
2891
{
RefKind
: RefKind.None, ReturnsVoid: true } => method.ReturnsVoid,
2892
{
RefKind
: var destinationRefKind } => hasConversion(
2897
sourceRefKind: method.
RefKind
,
Binder\Binder_Expressions.cs (2)
10198
getMethod.
RefKind
== RefKind.None &&
10802
var returnRefKind = returnRefKindOverride ?? methodSymbol.
RefKind
;
Binder\Binder_Statements.cs (2)
1338
!patternMethodSymbol.
RefKind
.IsManagedReference() ||
2968
refKind = symbol.
RefKind
;
Binder\ExecutableCodeBinder.cs (1)
136
RefKind refKind = iterator.
RefKind
;
Binder\ForEachLoopBinder.cs (1)
866
builder.CurrentPropertyGetter?.
RefKind
== (wellKnownSpan == WellKnownType.System_ReadOnlySpan_T ? RefKind.RefReadOnly : RefKind.Ref)) ||
Binder\InMethodBinder.cs (1)
127
RefKind refKind = _methodSymbol.
RefKind
;
Binder\LockBinder.cs (1)
80
if (enterScopeMethod is not { ReturnsVoid: false,
RefKind
: RefKind.None })
Binder\Semantics\Conversions\Conversions.cs (3)
258
returnRefKind: delegateInvokeMethodOpt.
RefKind
, returnType: delegateInvokeMethodOpt.ReturnType,
364
isMethodGroupConversion: true, returnRefKind: invokeMethodOpt?.
RefKind
, delegateOrFunctionPointerType: targetType);
393
returnRefKind: delegateInvokeMethod.
RefKind
,
Binder\Semantics\Conversions\ConversionsBase.cs (1)
1487
if (invokeMethod.
RefKind
!= refKind ||
Binder\Semantics\OverloadResolution\OverloadResolution.cs (1)
882
else if (method.
RefKind
!= returnRefKind)
BoundTree\BoundExpressionExtensions.cs (1)
34
return ((BoundCall)node).Method.
RefKind
;
BoundTree\UnboundLambda.cs (1)
645
refKind = invokeMethod.
RefKind
;
CodeGen\CodeGenerator.cs (1)
169
var slotConstraints = _method.
RefKind
== RefKind.None
CodeGen\EmitAddress.cs (1)
181
var methodRefKind = call.Method.
RefKind
;
CodeGen\EmitExpression.cs (6)
1739
var methodRefKind = call.Method.
RefKind
;
2220
return ((BoundCall)receiver).Method.
RefKind
!= RefKind.None;
2931
Debug.Assert(left.Method.
RefKind
!= RefKind.None);
3133
Debug.Assert(((BoundCall)expression).Method.
RefKind
!= RefKind.None);
4088
if (useKind == UseKind.UsedAsValue && method.
RefKind
!= RefKind.None)
4094
Debug.Assert(method.
RefKind
!= RefKind.None);
CodeGen\EmitStatement.cs (1)
873
var unexpectedTemp = this.EmitAddress(expressionOpt, this._method.
RefKind
== RefKind.RefReadOnly ? AddressKind.ReadOnlyStrict : AddressKind.Writeable);
CodeGen\Optimizer.cs (1)
1057
Debug.Assert(((BoundCall)lhs).Method.
RefKind
== RefKind.Ref, "only ref returning methods are assignable");
Compilation\CSharpCompilation.cs (1)
2221
if (method.
RefKind
!= RefKind.None)
Emitter\EditAndContinue\CSharpSymbolMatcher.cs (2)
602
method.
RefKind
.Equals(other.
RefKind
) &&
Emitter\Model\MethodReference.cs (1)
105
return UnderlyingMethod.
RefKind
.IsManagedReference();
Emitter\Model\MethodSymbolAdapter.cs (1)
236
return AdaptedMethodSymbol.
RefKind
.IsManagedReference();
Lowering\AsyncRewriter\AsyncMethodBuilderMemberCollection.cs (1)
488
method.
RefKind
== RefKind.None &&
Lowering\DiagnosticsPass_ExpressionTrees.cs (1)
347
else if (method.
RefKind
!= RefKind.None)
Lowering\LocalRewriter\LocalRewriter.cs (1)
1087
return ((BoundCall)expr).Method.
RefKind
!= RefKind.None;
Lowering\LocalRewriter\LocalRewriter_CompoundAssignmentOperator.cs (1)
699
Debug.Assert(((BoundCall)originalLHS).Method.
RefKind
!= RefKind.None);
Lowering\StateMachineRewriter\MethodToStateMachineRewriter.cs (1)
625
Debug.Assert(call.Method.
RefKind
!= RefKind.None);
Lowering\SynthesizedMethodBaseSymbol.cs (1)
42
refKind: baseMethod.
RefKind
,
Lowering\SyntheticBoundNodeFactory.cs (2)
561
Debug.Assert(CurrentFunction.
RefKind
== RefKind.None);
566
return new BoundReturnStatement(Syntax, CurrentFunction.
RefKind
, expression, @checked: false) { WasCompilerGenerated = true };
Symbols\Compilation_WellKnownMembers.cs (1)
1177
return method.
RefKind
!= RefKind.None;
Symbols\MethodSymbol.cs (4)
218
return this.
RefKind
== RefKind.Ref;
229
Debug.Assert(this.
RefKind
!= RefKind.Out);
230
return this.
RefKind
== RefKind.RefReadOnly;
1163
AddSynthesizedAttribute(ref attributes, compilation.SynthesizeDynamicAttribute(type.Type, type.CustomModifiers.Length + this.RefCustomModifiers.Length, this.
RefKind
));
Symbols\PublicModel\MethodSymbol.cs (1)
327
RefKind IMethodSymbol.RefKind => _underlying.
RefKind
;
Symbols\ReducedExtensionMethodSymbol.cs (1)
489
get { return _reducedFrom.
RefKind
; }
Symbols\Retargeting\RetargetingSymbolTranslator.cs (1)
1022
method.
RefKind
,
Symbols\Source\CustomModifierUtils.cs (1)
43
destinationMethod.
RefKind
!= RefKind.None ? constructedSourceMethod.RefCustomModifiers : ImmutableArray<CustomModifier>.Empty;
Symbols\Source\LocalFunctionOrSourceMemberMethodSymbol.cs (1)
29
TypeWithAnnotations elementType = InMethodBinder.GetIteratorElementTypeFromReturnType(DeclaringCompilation,
RefKind
, ReturnType, errorLocation: null, diagnostics: null);
Symbols\Source\SourceMemberContainerSymbol_ImplementationChecks.cs (5)
987
if (overridingMethod.
RefKind
!= overriddenMethod.
RefKind
)
1268
overrideMethod.
RefKind
,
1278
overrideMethod.
RefKind
== RefKind.Ref ? RefKind.Ref : RefKind.Out,
1391
(method.
RefKind
is RefKind.Ref or RefKind.RefReadOnly))
Symbols\Source\SourceMethodSymbolWithAttributes.cs (2)
1393
checkAndReportManagedTypes(ReturnType, this.
RefKind
, returnTypeSyntax, isParam: false, diagnostics);
1524
if (this.
RefKind
!= RefKind.None)
Symbols\SymbolExtensions.cs (1)
500
refKind = method.
RefKind
;
Symbols\Synthesized\SynthesizedImplementationMethod.cs (1)
98
get { return _interfaceMethod.
RefKind
; }
Symbols\Synthesized\SynthesizedSealedPropertyAccessor.cs (1)
185
return _overriddenAccessor.
RefKind
;
Symbols\TypeSymbol.cs (3)
1606
interfaceMethod.
RefKind
,
2008
interfaceMemberRefKind = method.
RefKind
;
2027
hasRefReturnMismatch = ((MethodSymbol)closestMismatch).
RefKind
!= interfaceMemberRefKind;
Symbols\VarianceSafety.cs (2)
163
requireInputSafety: method.
RefKind
!= RefKind.None,
199
requireInputSafety: hasSetter || !(property.GetMethod?.
RefKind
== RefKind.None),
Symbols\Wrapped\WrappedMethodSymbol.cs (1)
60
return UnderlyingMethod.
RefKind
;