File tree Expand file tree Collapse file tree 2 files changed +9
-0
lines changed Expand file tree Collapse file tree 2 files changed +9
-0
lines changed Original file line number Diff line number Diff line change @@ -14046,6 +14046,11 @@ ConstraintSystem::simplifyExplicitGenericArgumentsConstraint(
14046
14046
14047
14047
auto genericParams = getGenericParams(decl);
14048
14048
if (!decl->getAsGenericContext() || !genericParams) {
14049
+ // Allow Macros to have specializations that we don't think they need.
14050
+ if (isa<MacroDecl>(decl)) {
14051
+ return SolutionKind::Solved;
14052
+ }
14053
+
14049
14054
return recordFix(AllowConcreteTypeSpecialization::create(
14050
14055
*this, type1, getConstraintLocator(locator)))
14051
14056
? SolutionKind::Error
Original file line number Diff line number Diff line change @@ -69,4 +69,8 @@ struct TestMacroArgs {
69
69
// expected-error@-1{{missing argument for parameter #1 in macro expansion}}
70
70
71
71
@m3 ( message: #stringify ( Nested . x) . 1 ) struct Args8 { }
72
+
73
+ // Allow macros to have arbitrary generic specialization lists
74
+ // https://github.com/swiftlang/swift/issues/75500
75
+ @m1 < UInt > struct Args9 { }
72
76
}
You can’t perform that action at this time.
0 commit comments