We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8292cbe commit 043d76aCopy full SHA for 043d76a
lib/Sema/TypeCheckDecl.cpp
@@ -2941,6 +2941,9 @@ class DeclChecker : public DeclVisitor<DeclChecker> {
2941
TC.validateDecl(EED);
2942
TC.checkDeclAttributes(EED);
2943
2944
+ if (auto *PL = EED->getParameterList())
2945
+ TC.checkDefaultArguments(PL, EED);
2946
+
2947
checkAccessControl(TC, EED);
2948
}
2949
@@ -4098,7 +4101,6 @@ void TypeChecker::validateDecl(ValueDecl *D) {
4098
4101
EED->getParentEnum(),
4099
4102
ED->getGenericSignature()),
4100
4103
TypeResolverContext::EnumElementDecl);
- checkDefaultArguments(PL, EED);
4104
4105
4106
// If we have a raw value, make sure there's a raw type as well.
0 commit comments