70 references to SkipScoped
Microsoft.CodeAnalysis.CSharp (25)
Binder\Binder_Deconstruct.cs (1)
754
var declType = BindVariableTypeWithAnnotations(component.Designation, diagnostics, component.Type.
SkipScoped
(out _).SkipRef(), ref isConst, out isVar, out alias);
Binder\Binder_Expressions.cs (1)
970
var declType = BindVariableTypeWithAnnotations(node.Designation, diagnostics, node.Type.
SkipScoped
(out _).SkipRef(), ref isConst, out isVar, out alias);
Binder\Binder_Lambda.cs (1)
297
syntax = syntax.
SkipScoped
(out _).SkipRefInLocalOrReturn(diagnostics, out RefKind refKind);
Binder\Binder_Statements.cs (1)
804
TypeWithAnnotations declType = BindTypeOrVarKeyword(typeSyntax.
SkipScoped
(out _).SkipRef(), diagnostics, out isVar, out alias);
Binder\ForLoopBinder.cs (1)
75
var type = _syntax.Declaration.Type.
SkipScoped
(out _);
BoundTree\VariablePendingInference.cs (1)
70
(typeOrDesignationSyntax is TypeSyntax typeSyntax ? typeSyntax.
SkipScoped
(out _).SkipRef() : typeOrDesignationSyntax).Location);
Symbols\Source\GlobalExpressionVariable.cs (2)
55
return (typeSyntax == null || typeSyntax.
SkipScoped
(out _).SkipRef().IsVar)
93
type = binder.BindTypeOrVarKeyword(typeSyntax.
SkipScoped
(out _).SkipRef(), diagnostics, out isVar);
Symbols\Source\LocalFunctionSymbol.cs (1)
259
TypeWithAnnotations returnType = WithTypeParametersBinder.BindType(returnTypeSyntax.
SkipScoped
(out _).SkipRef(), diagnostics);
Symbols\Source\SourceDelegateMethodSymbol.cs (1)
56
returnTypeSyntax = returnTypeSyntax.
SkipScoped
(out _).SkipRefInLocalOrReturn(diagnostics, out RefKind refKind);
Symbols\Source\SourceLocalSymbol.cs (5)
93
typeSyntax = typeSyntax.
SkipScoped
(out isScoped);
178
return closestTypeSyntax.
SkipScoped
(out _).SkipRef().IsVar
210
return typeSyntax?.
SkipScoped
(out _).SkipRef().IsVar != false && kind != LocalDeclarationKind.DeclarationExpressionVariable
349
TypeSyntax typeSyntax = _typeSyntax.
SkipScoped
(out _).SkipRef();
396
declType = typeBinder.BindTypeOrVarKeyword(_typeSyntax.
SkipScoped
(out _).SkipRef(), BindingDiagnosticBag.Discarded, out isVar);
Symbols\Source\SourceMemberContainerSymbol.cs (1)
5518
_ = fieldSyntax.Declaration.Type.
SkipScoped
(out _).SkipRefInField(out var refKind);
Symbols\Source\SourceMemberFieldSymbol.cs (4)
499
var typeOnly = typeSyntax.
SkipScoped
(out _).SkipRefInField(out refKind);
504
MessageID.IDS_FeatureRefFields.CheckFeatureAvailability(diagnostics, compilation, typeSyntax.
SkipScoped
(out _).Location);
512
diagnostics.Add(ErrorCode.ERR_RefFieldCannotReferToRefStruct, typeSyntax.
SkipScoped
(out _).Location);
518
type = binder.BindTypeOrVarKeyword(typeSyntax.
SkipScoped
(out _).SkipRefInField(out RefKind refKindToAssert), diagnostics, out isVar);
Symbols\Source\SourceOrdinaryMethodSymbol.cs (2)
95
methodKind, refKind: syntax.ReturnType.
SkipScoped
(out _).GetRefKindInLocalOrReturn(diagnostics),
137
returnTypeSyntax = returnTypeSyntax.
SkipScoped
(out _).SkipRef();
Symbols\Source\SourcePropertySymbol.cs (2)
137
syntax.Type.
SkipScoped
(out _).GetRefKindInLocalOrReturn(diagnostics),
576
typeSyntax = typeSyntax.
SkipScoped
(out _).SkipRef();
Syntax\SyntaxFacts.cs (1)
456
return node == parent?.Type.
SkipScoped
(out _).SkipRef();
Microsoft.CodeAnalysis.CSharp.Semantic.UnitTests (45)
Semantics\RefFieldTests.cs (45)
12106
Assert.True(SyntaxFacts.IsInTypeOnlyContext(type.
SkipScoped
(out _)));
12107
Assert.True(SyntaxFacts.IsInTypeOnlyContext(type.
SkipScoped
(out _).SkipRef()));
12112
type = type.
SkipScoped
(out _);
12176
type = type.
SkipScoped
(out _);
12240
Assert.True(SyntaxFacts.IsInTypeOnlyContext(type.
SkipScoped
(out _)));
12241
Assert.True(SyntaxFacts.IsInTypeOnlyContext(type.
SkipScoped
(out _).SkipRef()));
12246
type = type.
SkipScoped
(out _);
12429
Assert.True(SyntaxFacts.IsInTypeOnlyContext(type.
SkipScoped
(out _)));
12430
Assert.True(SyntaxFacts.IsInTypeOnlyContext(type.
SkipScoped
(out _).SkipRef()));
12435
type = type.
SkipScoped
(out _);
12461
Assert.True(SyntaxFacts.IsInTypeOnlyContext(type.
SkipScoped
(out _)));
12462
Assert.True(SyntaxFacts.IsInTypeOnlyContext(type.
SkipScoped
(out _).SkipRef()));
12467
type = type.
SkipScoped
(out _);
12615
type = type.
SkipScoped
(out _);
12643
type = type.
SkipScoped
(out _);
12840
Assert.True(SyntaxFacts.IsInTypeOnlyContext(type.
SkipScoped
(out _)));
12841
Assert.True(SyntaxFacts.IsInTypeOnlyContext(type.
SkipScoped
(out _).SkipRef()));
12846
type = type.
SkipScoped
(out _);
12874
Assert.True(SyntaxFacts.IsInTypeOnlyContext(type.
SkipScoped
(out _)));
12875
Assert.True(SyntaxFacts.IsInTypeOnlyContext(type.
SkipScoped
(out _).SkipRef()));
12880
type = type.
SkipScoped
(out _);
13022
type = type.
SkipScoped
(out _);
13050
type = type.
SkipScoped
(out _);
13488
type = type.
SkipScoped
(out _);
13552
type = type.
SkipScoped
(out _);
13629
type = type.
SkipScoped
(out _);
13699
type = type.
SkipScoped
(out _);
14393
Assert.Equal("R", model.GetSymbolInfo(type.
SkipScoped
(out _).SkipRef()).Symbol.ToTestDisplayString());
14435
Assert.Equal("R", model.GetSymbolInfo(type.
SkipScoped
(out _).SkipRef()).Symbol.ToTestDisplayString());
14640
Assert.True(SyntaxFacts.IsInTypeOnlyContext(type.
SkipScoped
(out _)));
14641
Assert.True(SyntaxFacts.IsInTypeOnlyContext(type.
SkipScoped
(out _).SkipRef()));
14646
type = type.
SkipScoped
(out _);
14890
type = type.
SkipScoped
(out _);
14918
type = type.
SkipScoped
(out _);
15181
type = type.
SkipScoped
(out _);
27582
Assert.True(SyntaxFacts.IsInTypeOnlyContext(type.
SkipScoped
(out _)));
27583
Assert.True(SyntaxFacts.IsInTypeOnlyContext(type.
SkipScoped
(out _).SkipRef()));
27588
type = type.
SkipScoped
(out _);
27672
Assert.True(SyntaxFacts.IsInTypeOnlyContext(type.
SkipScoped
(out _)));
27673
Assert.True(SyntaxFacts.IsInTypeOnlyContext(type.
SkipScoped
(out _).SkipRef()));
27678
type = type.
SkipScoped
(out _);
27945
type = type.
SkipScoped
(out _);
28005
type = type.
SkipScoped
(out _);
28224
Assert.Equal("R", model.GetSymbolInfo(type.
SkipScoped
(out _).SkipRef()).Symbol.ToTestDisplayString());
28272
Assert.Equal("R", model.GetSymbolInfo(type.
SkipScoped
(out _).SkipRef()).Symbol.ToTestDisplayString());