SyntaxTree.WithDiagnosticOptions Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Caution
Obsolete due to performance problems, use CompilationOptions.SyntaxTreeOptionsProvider instead
Returns a new tree whose DiagnosticOptions are the specified value and other properties are copied from the current tree.
public virtual Microsoft.CodeAnalysis.SyntaxTree WithDiagnosticOptions (System.Collections.Immutable.ImmutableDictionary<string,Microsoft.CodeAnalysis.ReportDiagnostic> options);
[System.Obsolete("Obsolete due to performance problems, use CompilationOptions.SyntaxTreeOptionsProvider instead", false)]
public virtual Microsoft.CodeAnalysis.SyntaxTree WithDiagnosticOptions (System.Collections.Immutable.ImmutableDictionary<string,Microsoft.CodeAnalysis.ReportDiagnostic> options);
abstract member WithDiagnosticOptions : System.Collections.Immutable.ImmutableDictionary<string, Microsoft.CodeAnalysis.ReportDiagnostic> -> Microsoft.CodeAnalysis.SyntaxTree
override this.WithDiagnosticOptions : System.Collections.Immutable.ImmutableDictionary<string, Microsoft.CodeAnalysis.ReportDiagnostic> -> Microsoft.CodeAnalysis.SyntaxTree
[<System.Obsolete("Obsolete due to performance problems, use CompilationOptions.SyntaxTreeOptionsProvider instead", false)>]
abstract member WithDiagnosticOptions : System.Collections.Immutable.ImmutableDictionary<string, Microsoft.CodeAnalysis.ReportDiagnostic> -> Microsoft.CodeAnalysis.SyntaxTree
override this.WithDiagnosticOptions : System.Collections.Immutable.ImmutableDictionary<string, Microsoft.CodeAnalysis.ReportDiagnostic> -> Microsoft.CodeAnalysis.SyntaxTree
Public Overridable Function WithDiagnosticOptions (options As ImmutableDictionary(Of String, ReportDiagnostic)) As SyntaxTree
Parameters
- options
- ImmutableDictionary<String,ReportDiagnostic>
A mapping from diagnostic id to diagnostic reporting level. The diagnostic ID may be case-sensitive depending on the language.
Returns
- Attributes
Applies to
Współpracuj z nami w serwisie GitHub
Źródło tej zawartości można znaleźć w witrynie GitHub, gdzie można również tworzyć i przeglądać problemy i żądania ściągnięcia. Więcej informacji znajdziesz w naszym przewodniku dla współtwórców.