1 type derived from SyntaxTreeSemanticModel
Microsoft.CodeAnalysis.CSharp (1)
Compilation\SpeculativeSyntaxTreeSemanticModel.cs (1)
19
internal class SpeculativeSyntaxTreeSemanticModel :
SyntaxTreeSemanticModel
1 instantiation of SyntaxTreeSemanticModel
Microsoft.CodeAnalysis.CSharp (1)
Compilation\CSharpCompilation.cs (1)
2538
=> new
SyntaxTreeSemanticModel
(this, syntaxTree, options);
94 references to SyntaxTreeSemanticModel
Microsoft.CodeAnalysis.CSharp (94)
Compilation\AttributeSemanticModel.cs (8)
48
public static SpeculativeSemanticModelWithMemberModel CreateSpeculative(
SyntaxTreeSemanticModel
parentSemanticModel, AttributeSyntax syntax, NamedTypeSymbol attributeType, AliasSymbol aliasOpt, Binder rootBinder, ImmutableDictionary<Symbol, Symbol> parentRemappedSymbolsOpt, int position)
128
internal override bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, ConstructorInitializerSyntax constructorInitializer, out PublicSemanticModel? speculativeModel)
134
internal override bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, PrimaryConstructorBaseTypeSyntax constructorInitializer, out PublicSemanticModel? speculativeModel)
140
internal override bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, EqualsValueClauseSyntax initializer, out PublicSemanticModel? speculativeModel)
146
internal override bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, ArrowExpressionClauseSyntax expressionBody, out PublicSemanticModel? speculativeModel)
152
internal override bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, StatementSyntax statement, out PublicSemanticModel? speculativeModel)
158
internal override bool TryGetSpeculativeSemanticModelForMethodBodyCore(
SyntaxTreeSemanticModel
parentModel, int position, BaseMethodDeclarationSyntax method, out PublicSemanticModel? speculativeModel)
164
internal override bool TryGetSpeculativeSemanticModelForMethodBodyCore(
SyntaxTreeSemanticModel
parentModel, int position, AccessorDeclarationSyntax accessor, out PublicSemanticModel? speculativeModel)
Compilation\CSharpSemanticModel.cs (19)
2520
var result = TryGetSpeculativeSemanticModelForMethodBodyCore((
SyntaxTreeSemanticModel
)this, position, method, out PublicSemanticModel speculativeSyntaxTreeModel);
2525
internal abstract bool TryGetSpeculativeSemanticModelForMethodBodyCore(
SyntaxTreeSemanticModel
parentModel, int position, BaseMethodDeclarationSyntax method, out PublicSemanticModel speculativeModel);
2547
var result = TryGetSpeculativeSemanticModelForMethodBodyCore((
SyntaxTreeSemanticModel
)this, position, accessor, out PublicSemanticModel speculativeSyntaxTreeModel);
2552
internal abstract bool TryGetSpeculativeSemanticModelForMethodBodyCore(
SyntaxTreeSemanticModel
parentModel, int position, AccessorDeclarationSyntax accessor, out PublicSemanticModel speculativeModel);
2576
var result = TryGetSpeculativeSemanticModelCore((
SyntaxTreeSemanticModel
)this, position, type, bindingOption, out PublicSemanticModel speculativeSyntaxTreeModel);
2581
internal abstract bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, TypeSyntax type, SpeculativeBindingOption bindingOption, out PublicSemanticModel speculativeModel);
2602
var result = TryGetSpeculativeSemanticModelCore((
SyntaxTreeSemanticModel
)this, position, statement, out PublicSemanticModel speculativeSyntaxTreeModel);
2607
internal abstract bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, StatementSyntax statement, out PublicSemanticModel speculativeModel);
2629
var result = TryGetSpeculativeSemanticModelCore((
SyntaxTreeSemanticModel
)this, position, initializer, out PublicSemanticModel speculativeSyntaxTreeModel);
2634
internal abstract bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, EqualsValueClauseSyntax initializer, out PublicSemanticModel speculativeModel);
2656
var result = TryGetSpeculativeSemanticModelCore((
SyntaxTreeSemanticModel
)this, position, expressionBody, out PublicSemanticModel speculativeSyntaxTreeModel);
2661
internal abstract bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, ArrowExpressionClauseSyntax expressionBody, out PublicSemanticModel speculativeModel);
2686
var result = TryGetSpeculativeSemanticModelCore((
SyntaxTreeSemanticModel
)this, position, constructorInitializer, out PublicSemanticModel speculativeSyntaxTreeModel);
2691
internal abstract bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, ConstructorInitializerSyntax constructorInitializer, out PublicSemanticModel speculativeModel);
2715
var result = TryGetSpeculativeSemanticModelCore((
SyntaxTreeSemanticModel
)this, position, constructorInitializer, out PublicSemanticModel speculativeSyntaxTreeModel);
2720
internal abstract bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, PrimaryConstructorBaseTypeSyntax constructorInitializer, out PublicSemanticModel speculativeModel);
2745
var result = TryGetSpeculativeSemanticModelCore((
SyntaxTreeSemanticModel
)this, position, crefSyntax, out PublicSemanticModel speculativeSyntaxTreeModel);
2750
internal abstract bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, CrefSyntax crefSyntax, out PublicSemanticModel speculativeModel);
2781
speculativeModel = ((
SyntaxTreeSemanticModel
)this).CreateSpeculativeAttributeSemanticModel(position, attribute, binder, aliasOpt, attributeType);
Compilation\InitializerSemanticModel.cs (10)
39
internal static InitializerSemanticModel Create(
SyntaxTreeSemanticModel
containingSemanticModel, CSharpSyntaxNode syntax, FieldSymbol fieldSymbol, Binder rootBinder)
49
internal static InitializerSemanticModel Create(
SyntaxTreeSemanticModel
containingSemanticModel, CSharpSyntaxNode syntax, PropertySymbol propertySymbol, Binder rootBinder)
69
internal static SpeculativeSemanticModelWithMemberModel CreateSpeculative(
SyntaxTreeSemanticModel
parentSemanticModel, Symbol owner, EqualsValueClauseSyntax syntax, Binder rootBinder, ImmutableDictionary<Symbol, Symbol> parentRemappedSymbolsOpt, int position)
203
internal override bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, EqualsValueClauseSyntax initializer, out PublicSemanticModel speculativeModel)
217
internal override bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, ConstructorInitializerSyntax constructorInitializer, out PublicSemanticModel speculativeModel)
223
internal override bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, PrimaryConstructorBaseTypeSyntax constructorInitializer, out PublicSemanticModel speculativeModel)
229
internal override bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, ArrowExpressionClauseSyntax expressionBody, out PublicSemanticModel speculativeModel)
235
internal override bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, StatementSyntax statement, out PublicSemanticModel speculativeModel)
241
internal override bool TryGetSpeculativeSemanticModelForMethodBodyCore(
SyntaxTreeSemanticModel
parentModel, int position, BaseMethodDeclarationSyntax method, out PublicSemanticModel speculativeModel)
247
internal override bool TryGetSpeculativeSemanticModelForMethodBodyCore(
SyntaxTreeSemanticModel
parentModel, int position, AccessorDeclarationSyntax accessor, out PublicSemanticModel speculativeModel)
Compilation\MemberSemanticModel.cs (2)
169
internal sealed override bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, TypeSyntax type, SpeculativeBindingOption bindingOption, out PublicSemanticModel speculativeModel)
184
internal sealed override bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, CrefSyntax crefSyntax, out PublicSemanticModel speculativeModel)
Compilation\MemberSemanticModel.SpeculativeMemberSemanticModel.cs (8)
62
return ((
SyntaxTreeSemanticModel
)_containingPublicSemanticModel.ParentModel).IsNullableAnalysisEnabledAtSpeculativePosition(_containingPublicSemanticModel.OriginalPositionForSpeculation, Root);
65
internal override bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, ConstructorInitializerSyntax constructorInitializer, out PublicSemanticModel speculativeModel)
70
internal override bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, PrimaryConstructorBaseTypeSyntax constructorInitializer, out PublicSemanticModel speculativeModel)
75
internal override bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, EqualsValueClauseSyntax initializer, out PublicSemanticModel speculativeModel)
80
internal override bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, ArrowExpressionClauseSyntax expressionBody, out PublicSemanticModel speculativeModel)
85
internal override bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, StatementSyntax statement, out PublicSemanticModel speculativeModel)
90
internal override bool TryGetSpeculativeSemanticModelForMethodBodyCore(
SyntaxTreeSemanticModel
parentModel, int position, BaseMethodDeclarationSyntax method, out PublicSemanticModel speculativeModel)
95
internal override bool TryGetSpeculativeSemanticModelForMethodBodyCore(
SyntaxTreeSemanticModel
parentModel, int position, AccessorDeclarationSyntax accessor, out PublicSemanticModel speculativeModel)
Compilation\MethodBodySemanticModel.cs (14)
61
internal static MethodBodySemanticModel Create(
SyntaxTreeSemanticModel
containingSemanticModel, MethodSymbol owner, InitialState initialState)
112
SyntaxTreeSemanticModel
parentSemanticModel,
124
SyntaxTreeSemanticModel
parentSemanticModel,
138
internal static SpeculativeSemanticModelWithMemberModel CreateSpeculative(
SyntaxTreeSemanticModel
parentSemanticModel, MethodSymbol owner, ArrowExpressionClauseSyntax syntax, Binder rootBinder, int position)
146
internal static SpeculativeSemanticModelWithMemberModel CreateSpeculative(
SyntaxTreeSemanticModel
parentSemanticModel, MethodSymbol owner, ConstructorInitializerSyntax syntax, Binder rootBinder, int position)
154
internal static SpeculativeSemanticModelWithMemberModel CreateSpeculative(
SyntaxTreeSemanticModel
parentSemanticModel, MethodSymbol owner, PrimaryConstructorBaseTypeSyntax syntax, Binder rootBinder, int position)
159
internal override bool TryGetSpeculativeSemanticModelForMethodBodyCore(
SyntaxTreeSemanticModel
parentModel, int position, BaseMethodDeclarationSyntax method, out PublicSemanticModel speculativeModel)
165
private bool GetSpeculativeSemanticModelForMethodBody(
SyntaxTreeSemanticModel
parentModel, int position, BlockSyntax body, out PublicSemanticModel speculativeModel)
197
internal override bool TryGetSpeculativeSemanticModelForMethodBodyCore(
SyntaxTreeSemanticModel
parentModel, int position, AccessorDeclarationSyntax accessor, out PublicSemanticModel speculativeModel)
202
internal override bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, StatementSyntax statement, out PublicSemanticModel speculativeModel)
220
internal override bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, ArrowExpressionClauseSyntax expressionBody, out PublicSemanticModel speculativeModel)
239
internal override bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, ConstructorInitializerSyntax constructorInitializer, out PublicSemanticModel speculativeModel)
258
internal override bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, PrimaryConstructorBaseTypeSyntax constructorInitializer, out PublicSemanticModel speculativeModel)
281
internal override bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, EqualsValueClauseSyntax initializer, out PublicSemanticModel speculativeModel)
Compilation\SpeculativeSemanticModelWithMemberModel.cs (16)
22
private readonly
SyntaxTreeSemanticModel
_parentSemanticModel;
29
SyntaxTreeSemanticModel
parentSemanticModel,
42
SyntaxTreeSemanticModel
parentSemanticModel,
57
static Symbol? getAttributeTargetFromPosition(int position,
SyntaxTreeSemanticModel
model)
72
SyntaxTreeSemanticModel
parentSemanticModel,
88
SyntaxTreeSemanticModel
parentModel,
101
SyntaxTreeSemanticModel
parentSemanticModel,
520
internal override bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, ConstructorInitializerSyntax constructorInitializer, out PublicSemanticModel? speculativeModel)
525
internal override bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, PrimaryConstructorBaseTypeSyntax constructorInitializer, out PublicSemanticModel? speculativeModel)
530
internal override bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, EqualsValueClauseSyntax initializer, out PublicSemanticModel? speculativeModel)
535
internal override bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, ArrowExpressionClauseSyntax expressionBody, out PublicSemanticModel? speculativeModel)
540
internal override bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, StatementSyntax statement, out PublicSemanticModel? speculativeModel)
545
internal override bool TryGetSpeculativeSemanticModelForMethodBodyCore(
SyntaxTreeSemanticModel
parentModel, int position, BaseMethodDeclarationSyntax method, out PublicSemanticModel? speculativeModel)
550
internal override bool TryGetSpeculativeSemanticModelForMethodBodyCore(
SyntaxTreeSemanticModel
parentModel, int position, AccessorDeclarationSyntax accessor, out PublicSemanticModel? speculativeModel)
555
internal sealed override bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, TypeSyntax type, SpeculativeBindingOption bindingOption, out PublicSemanticModel speculativeModel)
560
internal sealed override bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, CrefSyntax crefSyntax, out PublicSemanticModel speculativeModel)
Compilation\SpeculativeSyntaxTreeSemanticModel.cs (6)
21
private readonly
SyntaxTreeSemanticModel
_parentSemanticModel;
27
public static SpeculativeSyntaxTreeSemanticModel Create(
SyntaxTreeSemanticModel
parentSemanticModel, TypeSyntax root, Binder rootBinder, int position, SpeculativeBindingOption bindingOption)
32
public static SpeculativeSyntaxTreeSemanticModel Create(
SyntaxTreeSemanticModel
parentSemanticModel, CrefSyntax root, Binder rootBinder, int position)
37
private static SpeculativeSyntaxTreeSemanticModel CreateCore(
SyntaxTreeSemanticModel
parentSemanticModel, CSharpSyntaxNode root, Binder rootBinder, int position, SpeculativeBindingOption bindingOption)
39
Debug.Assert(parentSemanticModel is
SyntaxTreeSemanticModel
);
49
private SpeculativeSyntaxTreeSemanticModel(
SyntaxTreeSemanticModel
parentSemanticModel, CSharpSyntaxNode root, Binder rootBinder, int position, SpeculativeBindingOption bindingOption)
Compilation\SyntaxTreeSemanticModel.cs (9)
594
internal sealed override bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, TypeSyntax type, SpeculativeBindingOption bindingOption, out PublicSemanticModel speculativeModel)
615
internal override bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, CrefSyntax crefSyntax, out PublicSemanticModel speculativeModel)
630
internal sealed override bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, StatementSyntax statement, out PublicSemanticModel speculativeModel)
644
internal sealed override bool TryGetSpeculativeSemanticModelForMethodBodyCore(
SyntaxTreeSemanticModel
parentModel, int position, BaseMethodDeclarationSyntax method, out PublicSemanticModel speculativeModel)
658
internal sealed override bool TryGetSpeculativeSemanticModelForMethodBodyCore(
SyntaxTreeSemanticModel
parentModel, int position, AccessorDeclarationSyntax accessor, out PublicSemanticModel speculativeModel)
672
internal sealed override bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, EqualsValueClauseSyntax initializer, out PublicSemanticModel speculativeModel)
686
internal override bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, ArrowExpressionClauseSyntax expressionBody, out PublicSemanticModel speculativeModel)
700
internal sealed override bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, ConstructorInitializerSyntax constructorInitializer, out PublicSemanticModel speculativeModel)
719
internal sealed override bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, PrimaryConstructorBaseTypeSyntax constructorInitializer, out PublicSemanticModel speculativeModel)
Compiler\MethodCompiler.cs (2)
1147
SyntaxTreeSemanticModel
semanticModelWithCachedBoundNodes = null;
1153
semanticModelWithCachedBoundNodes = (
SyntaxTreeSemanticModel
)cachingSemanticModelProvider.GetSemanticModel(syntax.SyntaxTree, _compilation);