18 references to IsConst
Microsoft.CodeAnalysis.CSharp (18)
Binder\Binder_Expressions.cs (1)
2029var constantValueOpt = localSymbol.IsConst && !IsInsideNameof && !type.IsErrorType()
CodeGen\EmitStatement.cs (2)
803if (!local.IsConst && !IsStackLocal(local)) 1765if (local.IsConst)
FlowAnalysis\DefiniteAssignment.cs (2)
1197if (symbol is LocalSymbol local && local.IsConst) 2261symbol.IsConst ||
Lowering\ClosureConversion\ClosureConversion.Analysis.Tree.cs (1)
619if (symbol is LocalSymbol local && local.IsConst)
Lowering\LocalRewriter\LocalRewriter_LocalDeclaration.cs (2)
34if (localSymbol.IsConst) 75if (this.Instrument && originalOpt?.WasCompilerGenerated == false && !localSymbol.IsConst &&
Lowering\StateMachineRewriter\IteratorAndAsyncCaptureWalker.cs (2)
143LocalSymbol { IsConst: false, IsPinned: false, IsRef: false } local => 162if (!((LocalSymbol)symbol).IsConst)
Lowering\StateMachineRewriter\StateMachineRewriter.cs (1)
164if (local.IsConst)
Symbols\LocalSymbol.cs (3)
55internal virtual bool CanScheduleToStack => !IsConst && !IsPinned; 325if (!this.IsConst) 343if (!this.IsConst)
Symbols\PublicModel\LocalSymbol.cs (1)
48bool ILocalSymbol.IsConst => _underlying.IsConst;
Symbols\Source\SourceLocalSymbol.cs (2)
558if (this.IsConst && _constantTuple == null) 577if (this.IsConst && inProgress == this)
Symbols\Symbol.cs (1)
1716if (((LocalSymbol)variable).IsConst)