-
Notifications
You must be signed in to change notification settings - Fork 69
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
Added serialization and token collection. #31
base: master
Are you sure you want to change the base?
Conversation
…fy that output can be parsed and that the parse result is identical to input parse result (but that might be a stretch...)
…le for the serialization
… (takes too long)
Hi Craxic, I noticed your work on your fork for quite a while. It's very impressive indeed. When you read the following, please keep in mind that even if I voice criticism I think you did a lot of tremendous work and I'm thankful that you put so much time into the project. I assume you had an itch to scratch. My biggest problem with this PR is that it is so huge. I like to have discrete units of work which are only as big as necessary. This applies to branches and doubly to commits (haven't checked those yet). The branch touches a LOT of things and is basically a complete reorganization of the whole code base. Based on my reaction time you can see that I can't put too much time into the project and this makes reviewing big changes harder than small ones. I have a few comments on what's probably only a fraction of what actually deserves commenting on. I'll add more once I get to it.
Those are my comments for now. As I said, this may take a while... :) |
Hi musiKk,
Thanks for getting back to me! |
Hi there!
I've been working pretty hard on this little project for some time now and I hope you like the stuff I've done. I've added the ability to write out the tree back to a Java file. So it's now possible to simply add and remove functions and variables just like you would do when modifying something like an HTML file. I've also tried to collect all the tokens from the parser and attach them to their model classes. This would make it easy for someone to find the exact location of something inside a Java file. I've also added a test that pulls all of openjdk7 and runs the parser against them to ensure that the parser succeeds without error. It also serializes and then de-serializes the result to ensure that serialization results in an identical tree as the original parse. Unfortunately, it takes too long on Travis (>50 minutes) so I disabled it when running in Travis. I've also re-factored the two source files into many separate source files because I think it's nicer that way. If you don't like it I'm sure we can fix it!
There are a couple of other reasons why you may not want to accept this pull request:
Anyways, I hope you like it. Let me know!