35 references to GeneratorDiagnostics
Microsoft.Interop.LibraryImportGenerator.Downlevel (35)
DiagnosticDescriptorProvider.cs (12)
11public DiagnosticDescriptor InvalidMarshallingAttributeInfo => GeneratorDiagnostics.MarshallingAttributeConfigurationNotSupported; 13public DiagnosticDescriptor ConfigurationNotSupported => GeneratorDiagnostics.ConfigurationNotSupported; 15public DiagnosticDescriptor ConfigurationValueNotSupported => GeneratorDiagnostics.ConfigurationValueNotSupported; 21GeneratorDiagnostic.NotSupported { NotSupportedDetails: null, TypePositionInfo: { IsManagedReturnPosition: true, MarshallingAttributeInfo: MarshalAsInfo } } => GeneratorDiagnostics.MarshalAsReturnConfigurationNotSupported, 22GeneratorDiagnostic.NotSupported { NotSupportedDetails: null, TypePositionInfo: { IsManagedReturnPosition: false, MarshallingAttributeInfo: MarshalAsInfo } } => GeneratorDiagnostics.MarshalAsParameterConfigurationNotSupported, 23GeneratorDiagnostic.NotSupported { NotSupportedDetails: not null, TypePositionInfo.IsManagedReturnPosition: true } => GeneratorDiagnostics.ReturnTypeNotSupportedWithDetails, 24GeneratorDiagnostic.NotSupported { NotSupportedDetails: not null, TypePositionInfo.IsManagedReturnPosition: false } => GeneratorDiagnostics.ParameterTypeNotSupportedWithDetails, 25GeneratorDiagnostic.UnnecessaryData { TypePositionInfo.IsManagedReturnPosition: false } => GeneratorDiagnostics.UnnecessaryParameterMarshallingInfo, 26GeneratorDiagnostic.UnnecessaryData { TypePositionInfo.IsManagedReturnPosition: true } => GeneratorDiagnostics.UnnecessaryReturnMarshallingInfo, 27GeneratorDiagnostic.NotRecommended => GeneratorDiagnostics.LibraryImportUsageDoesNotFollowBestPractices, 29{ TypePositionInfo.IsManagedReturnPosition: true } => GeneratorDiagnostics.ReturnTypeNotSupported, 30{ TypePositionInfo.IsManagedReturnPosition: false } => GeneratorDiagnostics.ParameterTypeNotSupported,
DownlevelLibraryImportDiagnosticsAnalyzer.cs (20)
25GeneratorDiagnostics.InvalidAttributedMethodSignature, 26GeneratorDiagnostics.InvalidAttributedMethodContainingTypeMissingModifiers, 27GeneratorDiagnostics.InvalidStringMarshallingConfiguration, 28GeneratorDiagnostics.ParameterTypeNotSupported, 29GeneratorDiagnostics.ReturnTypeNotSupported, 30GeneratorDiagnostics.ParameterTypeNotSupportedWithDetails, 31GeneratorDiagnostics.ReturnTypeNotSupportedWithDetails, 32GeneratorDiagnostics.ParameterConfigurationNotSupported, 33GeneratorDiagnostics.ReturnConfigurationNotSupported, 34GeneratorDiagnostics.MarshalAsParameterConfigurationNotSupported, 35GeneratorDiagnostics.MarshalAsReturnConfigurationNotSupported, 36GeneratorDiagnostics.ConfigurationNotSupported, 37GeneratorDiagnostics.ConfigurationValueNotSupported, 38GeneratorDiagnostics.MarshallingAttributeConfigurationNotSupported, 39GeneratorDiagnostics.CannotForwardToDllImport, 40GeneratorDiagnostics.RequiresAllowUnsafeBlocks); 77endContext.ReportDiagnostic(DiagnosticInfo.Create(GeneratorDiagnostics.RequiresAllowUnsafeBlocks, null).ToDiagnostic()); 286return DiagnosticInfo.Create(GeneratorDiagnostics.InvalidAttributedMethodSignature, methodSyntax.Identifier.GetLocation(), method.Name); 292return DiagnosticInfo.Create(GeneratorDiagnostics.InvalidAttributedMethodContainingTypeMissingModifiers, methodSyntax.Identifier.GetLocation(), method.Name, nonPartialIdentifier); 298return DiagnosticInfo.Create(GeneratorDiagnostics.ReturnConfigurationNotSupported, methodSyntax.Identifier.GetLocation(), "ref return", method.ToDisplayString());
GeneratorDiagnostics.cs (3)
133GeneratorDiagnostics.Ids.ConfigurationNotSupported, 144GeneratorDiagnostics.Ids.ConfigurationNotSupported, 281GeneratorDiagnostics.InvalidStringMarshallingConfiguration,