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

feature: add support for relative path with CtPath#relativePath #2506

Merged
merged 2 commits into from
Sep 23, 2018

Conversation

monperrus
Copy link
Collaborator

add support for relative path with CtPath#relativePath with a functional style

@Override
public CtPath relativePath(CtElement parent) {
Collection<CtElement> roots = new ArrayList<>();
((ArrayList<CtElement>) roots).add(parent);
Copy link
Collaborator

Choose a reason for hiding this comment

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

List<CtElement> roots = new ArrayList<>();
roots.add(parent);

WDYT?

@monperrus
Copy link
Collaborator Author

monperrus commented Sep 22, 2018 via email

@spoon-bot
Copy link
Collaborator

API changes: 2 (Detected by Revapi)

Old API: fr.inria.gforge.spoon:spoon-core:jar:7.1.0-20180921.224850-192 / New API: fr.inria.gforge.spoon:spoon-core:jar:7.1.0-SNAPSHOT

The return type changed covarianly from 'java.util.Collection' to 'java.util.List'.
Old method CtPath#evaluateOn(.Array)
New method CtPath#evaluateOn(.Array)
Breaking binary: breaking,
Method was added to an interface.
Old none
New method CtPath#relativePath(CtElement)
Breaking binary: non_breaking

@pvojtechovsky pvojtechovsky merged commit 0640db1 into INRIA:master Sep 23, 2018
@monperrus monperrus mentioned this pull request Oct 10, 2018
4 tasks
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.

3 participants