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

remove "implements Serializable" from ModuleFactory, PackageFactory an… #2173

Merged
merged 2 commits into from
Jul 5, 2018

Conversation

ashutosh1598
Copy link
Contributor

@ashutosh1598 ashutosh1598 commented Jul 5, 2018

…d DefaultCoreFactory. This PR is alternative to #2169. Instead of adding a constructor to SubFactory, it makes these subclasses unserializable.

Apart from these 3 bugs, it also removes (DOESN'T)two bugs of Sonar Rule 1948, since ModuleFactory will no longer be Serializable.

Edit : It won't remove those two bugs of rule 1948 because these fields are in a nested class which is also Serializable.

@monperrus
Copy link
Collaborator

We have an "unused import" CI error. I guess it's too hard to quickly fix the sniper mode for this, could you remove it manually?

@spoon-bot
Copy link
Collaborator

API changes: 3 (Detected by Revapi)

Old API: fr.inria.gforge.spoon:spoon-core:jar:7.1.0-20180705.100045-7 / New API: fr.inria.gforge.spoon:spoon-core:jar:7.1.0-SNAPSHOT

Class no longer implements interface 'java.io.Serializable'.
Old class ModuleFactory
New class ModuleFactory
Breaking binary: breaking,
Class no longer implements interface 'java.io.Serializable'.
Old class PackageFactory
New class PackageFactory
Breaking binary: breaking,
Class no longer implements interface 'java.io.Serializable'.
Old class DefaultCoreFactory
New class DefaultCoreFactory
Breaking binary: breaking,

@monperrus
Copy link
Collaborator

LGTM

@pvojtechovsky if you prefer this one over #2169, merge?

@pvojtechovsky pvojtechovsky merged commit b1e8172 into INRIA:master Jul 5, 2018
@pvojtechovsky
Copy link
Collaborator

@ashutosh1598 thank you for that cleaning 👍 and for experimenting with Sniper mode.

I have nearly no time this week so it needs longer until the known problems of Sniper mode are fixed ... be patient please.


/**
* The {@link CtPackage} sub-factory.
*/
public class PackageFactory extends SubFactory implements Serializable {
public class PackageFactory extends SubFactory {
private static final long serialVersionUID = 1L;
Copy link
Collaborator

Choose a reason for hiding this comment

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

serialVersionUID should be removed at the same time.

@monperrus monperrus mentioned this pull request Sep 20, 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.

5 participants