mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
Sema: Don't try to initialize static properties in implicit constructors.
The implicit default constructor shouldn't try to initialize static properties, and the implicit memberwise constructor shouldn't have arguments for static properties. Swift SVN r10378
This commit is contained in:
@@ -493,6 +493,8 @@ void PrintAST::visitExtensionDecl(ExtensionDecl *decl) {
|
||||
|
||||
void PrintAST::visitPatternBindingDecl(PatternBindingDecl *decl) {
|
||||
recordDeclLoc(decl);
|
||||
if (decl->isStatic())
|
||||
OS << "static ";
|
||||
OS << "var ";
|
||||
printPattern(decl->getPattern());
|
||||
if (Options.VarInitializers) {
|
||||
|
||||
Reference in New Issue
Block a user