aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2009-06-17Renamed the Handler implementations.Reinier Zwitserloot
2009-06-17TrivialReinier Zwitserloot
2009-06-17Removed a debug print.Reinier Zwitserloot
2009-06-17Error reporting now works 99% properly - the right position is being marked ↵Reinier Zwitserloot
off. The only issue is that the count by javac is being misreported (it doesn't count lombok errors).
2009-06-17Warnings and errors on specific positions works, sort of. Still missing ↵Reinier Zwitserloot
something crucial to properly make javac generate the line + the ^^^^ indicators.
2009-06-17NullPointerExceptions were showing up in Eclipse, when a 2+ dimensional ↵Reinier Zwitserloot
array of Statements contains inner arrays that are null. Fixed that.
2009-06-17Added reading in (via spi) JavacASTVisitors and calling them, as well as a ↵Reinier Zwitserloot
mechanism to generate generic errors and warnings for javac.
2009-06-17None of the methods in this class were even being used, so deleted the whole ↵Reinier Zwitserloot
thing.
2009-06-17Turns out using instanceof checks to figure out if a LocalDeclaration is a ↵Reinier Zwitserloot
method argument or not (by instanceof checking if it's an Argument) is faulty, as e.g. the argument to a catch block is also an Argument object. Rewritten the visitChild method to be based on a switch on the Node's getKind(), just like JavacAST. This even looks nicer.
2009-06-17Massive refactors. This list isn't complete, but should give you an idea:Reinier Zwitserloot
A) many things in lombok.eclipse moved to lombok.core to enable reuse with lombok.javac. B) lombok.javac works now similarly to eclipse's model: We first make big ASTs that are bidirectionally traversable, then we walk through that for annotations. C) Instead of getting an annotation instance, you now get an object that is more flexible and can e.g. give you class values in an enum as a string instead of a Class object, which may fail if that class isn't on the classpath of lombok. D) sources to the internal sun classes for javac added to /contrib.
2009-06-16Moved the generation of the Trees object to init(), as it seems to be the ↵Reinier Zwitserloot
same on every round.
2009-06-16Removed debug prints.Reinier Zwitserloot
2009-06-16Implemented a lot of stuff for javac, but we ran into 2 major issues still ↵Reinier Zwitserloot
to be implemented: 1. The visit mode of a lombok handler (does not trigger off of annotations, instead sees every field, method, type, and statement), needs to be coded, 2. triggering off of annotations via APT's annotation handling system skips method-local classes. We'll need to recode this via an AST visitor like we need for issue #1 Other than that, triggering off of annotations works swimmingly!
2009-06-16See diffReinier Zwitserloot
2009-06-16Added ability to add visitor handlers.Reinier Zwitserloot
2009-06-15Propagated the fact that you get the Node object belonging to the ↵Reinier Zwitserloot
annotation, and not the field/type/local/method it goes with, all the way, so that you can easily generate a warning on an annotation in a handler.
2009-06-15Switched the level of the Node object you get during a visitAnnotationOnX ↵Reinier Zwitserloot
call from the Field/Type/Method/Local to the Annotation, so that you can interact with its handled flag.
2009-06-15Added annotations as definitive children of nodes in our custom AST, and ↵Reinier Zwitserloot
updated the visitor to call a separate visitAnnotationOnX method for annotated stuff. This way, 'handled' can be set per annotation. Also fixed a bug in AST generation that caused StackOverflowErrors on most source files, and did some cosmetic renaming of parameters.
2009-06-15trivialReinier Zwitserloot
2009-06-15all eclipse AST Statements objects are now part of the custom AST we build ↵Reinier Zwitserloot
for lombok. This way something like @AutoClose on a local var declaration can walk up one node, find all mentions of the variable, and add a close call right after the last mention.
2009-06-15Fixed showstopper bugs we ran into when actually running with these changes. ↵Reinier Zwitserloot
Related to 8353911b1d3a8d59a07042976bb924a7eccb5d0d
2009-06-15Just in case people run lombok.jar as a java app (e.g. by double-clicking ↵Reinier Zwitserloot
it), open a browser window with info, and print some useful help to the console.
2009-06-15Moved version.txt to lombok.core.Version.java.Reinier Zwitserloot
2009-06-15Renamed lombok.transformations lombok.core as the purpose of this package is ↵Reinier Zwitserloot
to contain stuff that is useful for any lombok implementation (be it e.g. javac via apt or eclipse via agent), but not annotations and other classes that are for 'end users'.
2009-06-15Moved TypeResolver to the eclipse package, as it has eclipse-specific code ↵Reinier Zwitserloot
in it.
2009-06-15Renamed lombok.agent.eclipse to lombok.eclipse.agentReinier Zwitserloot
2009-06-15Now you no longer need to add a -Xbootclasspath/a parameter to eclipse.ini; ↵Reinier Zwitserloot
the agent fixes the classpath all by its lonesome. Wahey!
2009-06-14Made lombok more robust by catching exceptions near the top level and ↵Reinier Zwitserloot
turning them into eclipse-wide errors in the worst case, but usually in an error in the problems dialog.
2009-06-14Added support to generate errors, both on specific nodes in an AST ↵Reinier Zwitserloot
(generified code in HandlerLibrary for unintelligible annotation param values), and more severe general errors for eclipse's error log. Also unrolled the foreach loop on ServiceLoader, because any given .next() call can throw a ServiceLoaderError, which we now handle somewhat more nicely.
2009-06-12the version number generator now strips the newline. It was generating files ↵Reinier Zwitserloot
with newlines in it.
2009-06-12Error reporting now works - we can use the error reporting on decoding ↵Reinier Zwitserloot
annotation arguments for other places! Because this stuff works so well now, I bumped the version number as well.
2009-06-12Clinits should be skipped, as they are useless, and the docs even say they ↵Reinier Zwitserloot
will be skipped. Now they are skipped.
2009-06-12Whoops. Bugfix for enums. They get parsed correctly now!Reinier Zwitserloot
2009-06-12Now everything works; handlers are called via SPI, and annotations are being ↵Reinier Zwitserloot
parsed. w00t!
2009-06-12After spending 3 hours chasing down a NullPointerException inside the native ↵Reinier Zwitserloot
method that handles method.invoke... figured out that I accidentally added a second transform() method and that one was being found, and that somehow causes the problem. The locating of the right transform method now also checks params. A 'method not found' is faaaaaaaaaaaaaaar easier to debug than picking the wrong one out of the lineup.
2009-06-12Removed the WeakHashMap for caching EclipseAST objects; obviously wasn't ↵Reinier Zwitserloot
working due to circular reference from the EclipseAST back to the CUD. Now, patched a field into CompilationUnitDeclaration and using that, which works much better together with the garbage collector.
2009-06-12For the strangest reason, compiling Getter with javac fails; it wants ↵Reinier Zwitserloot
AccessLevel, but has AccessLevel. Yah, WTF. Turning AccessLevel into its FQN: lombok.AccessLevel fixes it. javac bug?
2009-06-12Found 2 bugs in spi. This fixes both of them. Also enabled the spi processor ↵Reinier Zwitserloot
in eclipse project.
2009-06-12Added a link to how JavaFX bindings work.Reinier Zwitserloot
2009-06-12There's nothing interesting in this file.Reinier Zwitserloot
2009-06-12Filled out the deps and lib system with separate dirs for the agent and ↵Reinier Zwitserloot
lombok proper, and moved spi into lombok's lib path.
2009-06-12Moved HandleGetter to its own package. This package should soon see ↵Reinier Zwitserloot
HandleSetter, HandleAutoClose, etc.
2009-06-12Incomplete work on pseudo-resolving something like "@Getter" to: Yes, this ↵Reinier Zwitserloot
is almost certainly intended to be lombok.Getter, so get to work!
2009-06-12Singularly massive code change, too hard to document. Basically, hooking now ↵Reinier Zwitserloot
occurs in the two most sane places: - After the parser is done building a first rendition of the AST. (Usually lightweight and missing method bodies etc) - After the parser is done taking such a lightweight AST and filling in the gaps. Lombok then builts its own bidirectional and somewhat saner AST out of this, and hands this saner AST off for treatment. Things in the AST can be marked as 'handled'. This seems to work swimmingly and should allow us to easily identify the annotations that are for us, and work our magic, no matter where they appear or on what, including stuff inside method bodies.
2009-06-12We were tracking ideas for annotations on the window, but writing on those ↵Reinier Zwitserloot
gets old fast, so moved it to a text file.
2009-06-10Added more good ideas.Reinier Zwitserloot
2009-06-09Build system splits the jars in two.Reinier Zwitserloot
2009-06-09Major bugfix.Reinier Zwitserloot
2009-06-09Many changes:Reinier Zwitserloot
- Split off the actual agent work into a separate src package in preparation for creating separate jars. Involved a lot of renaming - Renamed TransformCompilationUnitDeclaration to TransformEclipseAST, as this class will also be transforming e.g. MethodDeclaration objects. - Expanded the patching to also patch in transform calls when the parser fills in the Statement array for existing constructors, methods, and initializers. - Redesigned the ClassLoaderWorkaround class quite a bit. - Positioning should not work correctly ('jump to method' should jump to the getter annotation). (Apparently, Clinit objects are always fully parsed in the original run, so no need to patch anything there).
2009-06-08@Getter now TOTALLY WORKS in eclipse! W00t!Reinier Zwitserloot
Also made the handling of lombokisms in eclipse a little more frameworky, though there's still plenty to be done.