You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[ValueObject<decimal>(DefaultInstancePropertyName="Zero",// renames Amount.Empty to Amount.Zero
4
4
AllowDefaultStructs=true,
5
5
ComparisonOperators=OperatorsGeneration.DefaultWithKeyTypeOverloads,// for comparison of amount with a decimal without implicit conversion: amount > 42m
6
-
AdditionOperators=OperatorsGeneration.DefaultWithKeyTypeOverloads,// for arithmetic operations of amount with a decimal without implicit conversion: amount + 42m
AdditionOperators=OperatorsGeneration.DefaultWithKeyTypeOverloads,// for arithmetic operations of amount with a decimal without implicit conversion: amount + 42m
Copy file name to clipboardExpand all lines: src/Thinktecture.Runtime.Extensions.SourceGenerator/CodeAnalysis/CodeFixes/ThinktectureRuntimeExtensionsCodeFixProvider.cs
context.RegisterCodeFix(CodeAction.Create(_ALIGN_COMPARISON_EQUALITY_OPERATORS, t =>AlignComparisonEqualityOperatorsAsync(context.Document,root,GetCodeFixesContext().TypeDeclaration,t),_ALIGN_COMPARISON_EQUALITY_OPERATORS),diagnostic);
Copy file name to clipboardExpand all lines: src/Thinktecture.Runtime.Extensions.SourceGenerator/CodeAnalysis/Diagnostics/ThinktectureRuntimeExtensionsAnalyzer.cs
+45-2Lines changed: 45 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -60,6 +60,7 @@ public sealed class ThinktectureRuntimeExtensionsAnalyzer : DiagnosticAnalyzer
Copy file name to clipboardExpand all lines: src/Thinktecture.Runtime.Extensions.SourceGenerator/CodeAnalysis/DiagnosticsDescriptors.cs
+1Lines changed: 1 addition & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -54,6 +54,7 @@ internal static class DiagnosticsDescriptors
54
54
publicstaticreadonlyDiagnosticDescriptorExplicitComparerWithoutEqualityComparer=new("TTRESG102","The type has a comparer defined but no equality comparer","The type '{0}' has a comparer defined but no equality comparer",nameof(ThinktectureRuntimeExtensionsAnalyzer),DiagnosticSeverity.Warning,true);
55
55
publicstaticreadonlyDiagnosticDescriptorExplicitEqualityComparerWithoutComparer=new("TTRESG103","The type has an equality comparer defined but no comparer","The type '{0}' has an equality comparer defined but no comparer",nameof(ThinktectureRuntimeExtensionsAnalyzer),DiagnosticSeverity.Warning,true);
56
56
publicstaticreadonlyDiagnosticDescriptorMembersDisallowingDefaultValuesMustBeRequired=new("TTRESG104","The member must be marked as 'required' to ensure proper initialization","The {0} '{1}' of type '{2}' must be marked as 'required' to ensure proper initialization",nameof(ThinktectureRuntimeExtensionsAnalyzer),DiagnosticSeverity.Warning,true);
57
+
publicstaticreadonlyDiagnosticDescriptorComparisonAndEqualityOperatorsMismatch=new("TTRESG105","Comparison and equality operators settings mismatch","The type '{0}' has 'ComparisonOperators = {1}' and 'EqualityComparisonOperators = {2}' which differ. Set them to the same value.",nameof(ThinktectureRuntimeExtensionsAnalyzer),DiagnosticSeverity.Warning,true);
57
58
58
59
publicstaticreadonlyDiagnosticDescriptorInternalApiUsage=new("TTRESG1000","Internal Thinktecture.Runtime.Extensions API usage","'{0}' is an internal API that supports the Thinktecture.Runtime.Extensions infrastructure and not subject to the same compatibility standards as public APIs. It may be changed or removed without notice in any release.",nameof(ThinktectureRuntimeExtensionsInternalUsageAnalyzer),DiagnosticSeverity.Warning,true);
0 commit comments