11 references to SemanticModel
Microsoft.CodeAnalysis.CodeStyle (7)
src\Analyzers\Core\Analyzers\UseCollectionInitializer\AbstractObjectCreationExpressionAnalyzer.cs (1)
47
protected SemanticModel SemanticModel => this.State.
SemanticModel
;
src\Analyzers\Core\Analyzers\UseCollectionInitializer\UpdateExpressionState.cs (6)
112
SemanticModel
.GetSymbolInfo(subExpression, cancellationToken).GetAnySymbol()))
197
this.
SemanticModel
.GetSymbolInfo(invocationExpression, cancellationToken).Symbol is IMethodSymbol
202
var instanceType =
SemanticModel
.GetTypeInfo(instance, cancellationToken).Type;
256
if (this.
SemanticModel
.GetSymbolInfo(memberAccess, cancellationToken).GetAnySymbol() is not IMethodSymbol method)
271
var convertedType = this.
SemanticModel
.GetTypeInfo(SyntaxFacts.GetExpressionOfArgument(arguments[0]), cancellationToken).ConvertedType;
419
return TryAnalyzeForeachStatement(this.
SemanticModel
, statement);
Microsoft.CodeAnalysis.CSharp.CodeStyle (4)
src\Analyzers\CSharp\Analyzers\UseCollectionExpression\CSharpUseCollectionExpressionForFluentDiagnosticAnalyzer.cs (4)
137
state.
SemanticModel
, invocation, expressionType, isSingletonInstance: false, allowSemanticsChange, skipVerificationForReplacedNode: true, cancellationToken, out var changesSemantics))
156
var semanticModel = state.
SemanticModel
;
389
var member = state.
SemanticModel
.GetSymbolInfo(memberAccess, cancellationToken).Symbol;
394
var type = state.
SemanticModel
.GetTypeInfo(memberAccess.Expression, cancellationToken).Type;