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)
2518
=> 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)
2512
var result = TryGetSpeculativeSemanticModelForMethodBodyCore((
SyntaxTreeSemanticModel
)this, position, method, out PublicSemanticModel speculativeSyntaxTreeModel);
2517
internal abstract bool TryGetSpeculativeSemanticModelForMethodBodyCore(
SyntaxTreeSemanticModel
parentModel, int position, BaseMethodDeclarationSyntax method, out PublicSemanticModel speculativeModel);
2539
var result = TryGetSpeculativeSemanticModelForMethodBodyCore((
SyntaxTreeSemanticModel
)this, position, accessor, out PublicSemanticModel speculativeSyntaxTreeModel);
2544
internal abstract bool TryGetSpeculativeSemanticModelForMethodBodyCore(
SyntaxTreeSemanticModel
parentModel, int position, AccessorDeclarationSyntax accessor, out PublicSemanticModel speculativeModel);
2568
var result = TryGetSpeculativeSemanticModelCore((
SyntaxTreeSemanticModel
)this, position, type, bindingOption, out PublicSemanticModel speculativeSyntaxTreeModel);
2573
internal abstract bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, TypeSyntax type, SpeculativeBindingOption bindingOption, out PublicSemanticModel speculativeModel);
2594
var result = TryGetSpeculativeSemanticModelCore((
SyntaxTreeSemanticModel
)this, position, statement, out PublicSemanticModel speculativeSyntaxTreeModel);
2599
internal abstract bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, StatementSyntax statement, out PublicSemanticModel speculativeModel);
2621
var result = TryGetSpeculativeSemanticModelCore((
SyntaxTreeSemanticModel
)this, position, initializer, out PublicSemanticModel speculativeSyntaxTreeModel);
2626
internal abstract bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, EqualsValueClauseSyntax initializer, out PublicSemanticModel speculativeModel);
2648
var result = TryGetSpeculativeSemanticModelCore((
SyntaxTreeSemanticModel
)this, position, expressionBody, out PublicSemanticModel speculativeSyntaxTreeModel);
2653
internal abstract bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, ArrowExpressionClauseSyntax expressionBody, out PublicSemanticModel speculativeModel);
2678
var result = TryGetSpeculativeSemanticModelCore((
SyntaxTreeSemanticModel
)this, position, constructorInitializer, out PublicSemanticModel speculativeSyntaxTreeModel);
2683
internal abstract bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, ConstructorInitializerSyntax constructorInitializer, out PublicSemanticModel speculativeModel);
2707
var result = TryGetSpeculativeSemanticModelCore((
SyntaxTreeSemanticModel
)this, position, constructorInitializer, out PublicSemanticModel speculativeSyntaxTreeModel);
2712
internal abstract bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, PrimaryConstructorBaseTypeSyntax constructorInitializer, out PublicSemanticModel speculativeModel);
2737
var result = TryGetSpeculativeSemanticModelCore((
SyntaxTreeSemanticModel
)this, position, crefSyntax, out PublicSemanticModel speculativeSyntaxTreeModel);
2742
internal abstract bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, CrefSyntax crefSyntax, out PublicSemanticModel speculativeModel);
2773
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)
111
SyntaxTreeSemanticModel
parentSemanticModel,
123
SyntaxTreeSemanticModel
parentSemanticModel,
137
internal static SpeculativeSemanticModelWithMemberModel CreateSpeculative(
SyntaxTreeSemanticModel
parentSemanticModel, MethodSymbol owner, ArrowExpressionClauseSyntax syntax, Binder rootBinder, int position)
145
internal static SpeculativeSemanticModelWithMemberModel CreateSpeculative(
SyntaxTreeSemanticModel
parentSemanticModel, MethodSymbol owner, ConstructorInitializerSyntax syntax, Binder rootBinder, int position)
153
internal static SpeculativeSemanticModelWithMemberModel CreateSpeculative(
SyntaxTreeSemanticModel
parentSemanticModel, MethodSymbol owner, PrimaryConstructorBaseTypeSyntax syntax, Binder rootBinder, int position)
158
internal override bool TryGetSpeculativeSemanticModelForMethodBodyCore(
SyntaxTreeSemanticModel
parentModel, int position, BaseMethodDeclarationSyntax method, out PublicSemanticModel speculativeModel)
164
private bool GetSpeculativeSemanticModelForMethodBody(
SyntaxTreeSemanticModel
parentModel, int position, BlockSyntax body, out PublicSemanticModel speculativeModel)
196
internal override bool TryGetSpeculativeSemanticModelForMethodBodyCore(
SyntaxTreeSemanticModel
parentModel, int position, AccessorDeclarationSyntax accessor, out PublicSemanticModel speculativeModel)
201
internal override bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, StatementSyntax statement, out PublicSemanticModel speculativeModel)
219
internal override bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, ArrowExpressionClauseSyntax expressionBody, out PublicSemanticModel speculativeModel)
238
internal override bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, ConstructorInitializerSyntax constructorInitializer, out PublicSemanticModel speculativeModel)
257
internal override bool TryGetSpeculativeSemanticModelCore(
SyntaxTreeSemanticModel
parentModel, int position, PrimaryConstructorBaseTypeSyntax constructorInitializer, out PublicSemanticModel speculativeModel)
280
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)
1122
SyntaxTreeSemanticModel
semanticModelWithCachedBoundNodes = null;
1128
semanticModelWithCachedBoundNodes = (
SyntaxTreeSemanticModel
)cachingSemanticModelProvider.GetSemanticModel(syntax.SyntaxTree, _compilation);