19 references to ToDiagnostic
Microsoft.Interop.ComInterfaceGenerator (8)
Analyzers\ComInterfaceGeneratorDiagnosticsAnalyzer.cs (4)
126
context.ReportDiagnostic(diag.
ToDiagnostic
());
148
context.ReportDiagnostic(diag.
ToDiagnostic
());
159
context.ReportDiagnostic(diag.
ToDiagnostic
());
197
context.ReportDiagnostic(diag.
ToDiagnostic
());
Analyzers\GeneratedComInterfaceAttributeAnalyzer.cs (1)
44
context.ReportDiagnostic(comInterfaceAttribute.CreateDiagnosticInfo(GeneratorDiagnostics.InterfaceTypeNotSupported, unsupportedValue).
ToDiagnostic
());
Analyzers\VtableIndexStubDiagnosticsAnalyzer.cs (3)
86
context.ReportDiagnostic(invalidMethodDiagnostic.
ToDiagnostic
());
96
context.ReportDiagnostic(diag.
ToDiagnostic
());
103
context.ReportDiagnostic(diag.
ToDiagnostic
());
Microsoft.Interop.JavaScript.JSImportGenerator (3)
Analyzers\JSImportExportDiagnosticsAnalyzer.cs (3)
105
endContext.ReportDiagnostic(DiagnosticInfo.Create(RequiresAllowUnsafeBlocksDescriptor, null).
ToDiagnostic
());
125
context.ReportDiagnostic(invalidMethodDiagnostic.
ToDiagnostic
());
131
context.ReportDiagnostic(diagnostic.
ToDiagnostic
());
Microsoft.Interop.LibraryImportGenerator (5)
Analyzers\ConvertToLibraryImportAnalyzer.cs (1)
89
context.ReportDiagnostic(method.CreateDiagnosticInfo(ConvertToLibraryImport, properties.ToImmutable(), method.Name).
ToDiagnostic
());
Analyzers\DiagnosticReporter.cs (1)
19
public static DiagnosticReporter CreateForLocation(Location location, Action<Diagnostic> reportDiagnostic) => new((descriptor, properties, args) => reportDiagnostic(location.CreateDiagnosticInfo(descriptor, properties, args).
ToDiagnostic
()));
Analyzers\LibraryImportDiagnosticsAnalyzer.cs (3)
83
endContext.ReportDiagnostic(DiagnosticInfo.Create(GeneratorDiagnostics.RequiresAllowUnsafeBlocks, null).
ToDiagnostic
());
136
context.ReportDiagnostic(invalidMethodDiagnostic.
ToDiagnostic
());
147
context.ReportDiagnostic(diagnostic.
ToDiagnostic
());
Microsoft.Interop.LibraryImportGenerator.Downlevel (3)
DownlevelLibraryImportDiagnosticsAnalyzer.cs (3)
77
endContext.ReportDiagnostic(DiagnosticInfo.Create(GeneratorDiagnostics.RequiresAllowUnsafeBlocks, null).
ToDiagnostic
());
137
context.ReportDiagnostic(invalidMethodDiagnostic.
ToDiagnostic
());
146
context.ReportDiagnostic(diagnostic.
ToDiagnostic
());