Skip to content
Snippets Groups Projects
Commit 4c56d910 authored by Johannes Mey's avatar Johannes Mey
Browse files

create a special constructor when both components and relations are not empty

parent dca69ff0
No related branches found
No related tags found
No related merge requests found
Pipeline #4917 passed
...@@ -228,17 +228,7 @@ aspect Constructors { ...@@ -228,17 +228,7 @@ aspect Constructors {
} }
//--- needsConstructor --- //--- needsConstructor ---
syn boolean TypeDecl.needsConstructor() { syn boolean TypeDecl.needsConstructor() = !componentsTransitive().isEmpty() && !relationComponentsTransitive().isEmpty();
if (componentsTransitive().isEmpty()) {
return false;
}
if (!relationComponents().isEmpty()) {
return true;
}
return hasSuper()
&& getSuper().decl() != null
&& getSuper().decl().needsConstructor();
}
//--- inConstructor --- //--- inConstructor ---
/** /**
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment