2 writes to MemorySafetyRulesVersion
Microsoft.CodeAnalysis.CSharp (2)
CSharpCompilationOptions.cs (2)
299
this.
MemorySafetyRulesVersion
= memorySafetyRulesVersion;
503
return new CSharpCompilationOptions(this) {
MemorySafetyRulesVersion
= version };
13 references to MemorySafetyRulesVersion
Microsoft.CodeAnalysis.CSharp (12)
Compilation\CSharpCompilation.cs (2)
3105
nameof(Options.
MemorySafetyRulesVersion
), (int)Options.
MemorySafetyRulesVersion
, LanguageVersion.ToDisplayString(),
Compilation\CSharpDeterministicKeyBuilder.cs (1)
29
writer.Write("memorySafetyRulesVersion", (int)csharpOptions.
MemorySafetyRulesVersion
);
CSharpCompilationOptions.cs (9)
335
memorySafetyRulesVersion: other.
MemorySafetyRulesVersion
)
498
if (version == this.
MemorySafetyRulesVersion
)
509
internal bool UseUpdatedMemorySafetyRules =>
MemorySafetyRulesVersion
== MemorySafetyRulesVersion.Version2;
813
if (
MemorySafetyRulesVersion
is not (MemorySafetyRulesVersion.Version1 or MemorySafetyRulesVersion.Version2))
815
builder.Add(Diagnostic.Create(MessageProvider.Instance, (int)ErrorCode.ERR_BadCompilationOptionValueAccepted, nameof(
MemorySafetyRulesVersion
),
MemorySafetyRulesVersion
, string.Join(", ", [(int)MemorySafetyRulesVersion.Version1, (int)MemorySafetyRulesVersion.Version2])));
836
this.
MemorySafetyRulesVersion
== other.
MemorySafetyRulesVersion
&&
850
Hash.Combine((int)this.
MemorySafetyRulesVersion
,
Microsoft.CodeAnalysis.CSharp.Workspaces (1)
Serialization\CSharpOptionsSerializationService.cs (1)
34
writer.WriteByte((byte)csharpOptions.
MemorySafetyRulesVersion
);