Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor: check everywhere that Template is on source path of builder #979

Merged
merged 2 commits into from
Nov 17, 2016

Conversation

pvojtechovsky
Copy link
Collaborator

No description provided.

@@ -533,4 +537,40 @@ public static void redirectTypeReferences(CtElement element, CtTypeReference<?>
}
}

static <T> CtClass<T> getTemplateCtClass(CtType<?> targetType, Template<?> template) {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

javadoc?

return getTemplateCtClass(factory, template);
}

static <T> CtClass<T> getTemplateCtClass(Factory factory, Template<?> template) {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

javadoc?

@monperrus monperrus merged commit 204d9aa into INRIA:master Nov 17, 2016
@monperrus
Copy link
Collaborator

It seems that you like static methods very much. Why?

@pvojtechovsky
Copy link
Collaborator Author

Do you mean new static getTemplateCtClass in Substitution class? I do not like static. I like when algorithm is implemented only once and there are minimized dependencies. And it is the case now.

@monperrus
Copy link
Collaborator

Do you mean new static |getTemplateCtClass| in Substitution class? I
do not like static. I
OK, we're on the same page. I also think that static methods are bad
future unanticipated reuse with polymorphism and with respect to discovery.

@pvojtechovsky pvojtechovsky deleted the checkTemplateModelExists2 branch November 22, 2016 19:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants