6 overrides of IsReadOnly
Microsoft.CodeAnalysis.CSharp (5)
Symbols\AnonymousTypes\SynthesizedSymbols\AnonymousType.FieldSymbol.cs (1)
80public override bool IsReadOnly
Symbols\Metadata\PE\PEFieldSymbol.cs (1)
455public override bool IsReadOnly
Symbols\Source\FieldSymbolWithAttributesAndModifiers.cs (1)
48public sealed override bool IsReadOnly
Symbols\Synthesized\SynthesizedFieldSymbolBase.cs (1)
105public override bool IsReadOnly
Symbols\Wrapped\WrappedFieldSymbol.cs (1)
139public override bool IsReadOnly
Microsoft.CodeAnalysis.CSharp.ExpressionEvaluator.ExpressionCompiler (1)
Symbols\DisplayClassVariable.cs (1)
147public override bool IsReadOnly
31 references to IsReadOnly
Microsoft.CodeAnalysis.CSharp (11)
Binder\Binder.ValueChecks.cs (3)
945if (backingField.IsReadOnly) 1126if (fieldSymbol.IsReadOnly) 4760if (!field.IsReadOnly)
Binder\Binder_Attributes.cs (1)
613invalidNamedArgument |= fieldSymbol.IsReadOnly;
Binder\Binder_Expressions.cs (1)
5015if (isRhsNestedInitializer && fieldSymbol.IsReadOnly && fieldSymbol.Type.IsValueType)
Emitter\Model\FieldSymbolAdapter.cs (1)
201return AdaptedFieldSymbol.IsReadOnly || (AdaptedFieldSymbol.IsConst && !AdaptedFieldSymbol.IsMetadataConstant);
Emitter\NoPia\EmbeddedField.cs (1)
64return UnderlyingField.AdaptedFieldSymbol.IsReadOnly;
Lowering\SpillSequenceSpiller.cs (1)
411if (refKind != RefKind.None || fieldSymbol.IsReadOnly)
Lowering\StateMachineRewriter\MethodToStateMachineRewriter.cs (1)
572if (refKind != RefKind.None || field.FieldSymbol.IsReadOnly) return expr;
Symbols\PublicModel\FieldSymbol.cs (1)
84bool IFieldSymbol.IsReadOnly => _underlying.IsReadOnly;
Symbols\Wrapped\WrappedFieldSymbol.cs (1)
143return _underlyingField.IsReadOnly;
Microsoft.CodeAnalysis.CSharp.Emit.UnitTests (2)
CodeGen\CodeGenDynamicTests.cs (1)
603Assert.False(field.IsReadOnly);
Emit\EmitMetadataTests.cs (1)
1409Assert.False(field.IsReadOnly);
Microsoft.CodeAnalysis.CSharp.ExpressionEvaluator.ExpressionCompiler (1)
Symbols\DisplayClassVariable.cs (1)
103Debug.Assert(!field.IsReadOnly || GeneratedNameParser.GetKind(field.Name) == GeneratedNameKind.AnonymousTypeField);
Microsoft.CodeAnalysis.CSharp.Semantic.UnitTests (6)
Semantics\InitOnlyMemberTests.cs (1)
1489Assert.True(backingField.IsReadOnly);
Semantics\PrimaryConstructorTests.cs (5)
13602Assert.All(comp.GetTypeByMetadataName("S1").InstanceConstructors.OfType<SynthesizedPrimaryConstructor>().Single().GetBackingFields(), f => Assert.True(f.IsReadOnly)); 13798Assert.All(comp.GetTypeByMetadataName("S1").InstanceConstructors.OfType<SynthesizedPrimaryConstructor>().Single().GetBackingFields(), f => Assert.True(f.IsReadOnly)); 13999Assert.All(comp.GetTypeByMetadataName("S1").InstanceConstructors.OfType<SynthesizedPrimaryConstructor>().Single().GetBackingFields(), f => Assert.True(f.IsReadOnly)); 14225Assert.All(comp.GetTypeByMetadataName("S1").InstanceConstructors.OfType<SynthesizedPrimaryConstructor>().Single().GetBackingFields(), f => Assert.True(f.IsReadOnly)); 14536Assert.All(comp.GetTypeByMetadataName("S1").InstanceConstructors.OfType<SynthesizedPrimaryConstructor>().Single().GetBackingFields(), f => Assert.True(f.IsReadOnly));
Microsoft.CodeAnalysis.CSharp.Symbol.UnitTests (11)
Symbols\DefaultInterfaceImplementationTests.cs (4)
43752Assert.True(f1.IsReadOnly); 43753Assert.True(f2.IsReadOnly); 43754Assert.True(f3.IsReadOnly); 43755Assert.True(f4.IsReadOnly);
Symbols\Metadata\PE\LoadingFields.cs (6)
51Assert.False(f1.IsReadOnly); 66Assert.True(f2.IsReadOnly); 74Assert.False(f3.IsReadOnly); 82Assert.False(f4.IsReadOnly); 90Assert.False(f5.IsReadOnly); 98Assert.False(f6.IsReadOnly);
Symbols\Retargeting\RetargetCustomModifiers.cs (1)
186Assert.False(volatileFld.IsReadOnly);