diff options
author | Robbert Jan Grootjans <grootjans@gmail.com> | 2011-11-07 20:47:45 +0100 |
---|---|---|
committer | Robbert Jan Grootjans <grootjans@gmail.com> | 2011-11-07 20:47:45 +0100 |
commit | 99e36bf51c26152c53c8acefa90cce80af6da434 (patch) | |
tree | b92ac267d1a61c80212348cfad4e8bc754ecb71a | |
parent | e8495f0ddc8f6d08307d0a441c9f923d1d12766e (diff) | |
download | lombok-99e36bf51c26152c53c8acefa90cce80af6da434.tar.gz lombok-99e36bf51c26152c53c8acefa90cce80af6da434.tar.bz2 lombok-99e36bf51c26152c53c8acefa90cce80af6da434.zip |
Fixed issue 295: Using log in static initializers
-rw-r--r-- | doc/changelog.markdown | 3 | ||||
-rw-r--r-- | src/core/lombok/eclipse/handlers/EclipseHandlerUtil.java | 4 |
2 files changed, 5 insertions, 2 deletions
diff --git a/doc/changelog.markdown b/doc/changelog.markdown index 6db40d7e..c70e57cc 100644 --- a/doc/changelog.markdown +++ b/doc/changelog.markdown @@ -1,6 +1,9 @@ Lombok Changelog ---------------- +### v0.10.3 +* BUGFIX: Using the `log` field from `@Log`, etc, now works in static initializers. [Issue #295](http://code.google.com/p/projectlombok/issues/detail?id=295) + ### v0.10.2 (November 1st, 2011) * BUGFIX: Delombok will no longer jumble up comments from different files when using -sourcepath option. [Issue #284](http://code.google.com/p/projectlombok/issues/detail?id=284) * BUGFIX: Turns out treating `@NotNull` as an annotation that indicates lombok should generate nullcheck guards causes all sorts of problems. This has been removed again, and documentation has been updated to reflect this. [Issue #287](http://code.google.com/p/projectlombok/issues/detail?id=287) diff --git a/src/core/lombok/eclipse/handlers/EclipseHandlerUtil.java b/src/core/lombok/eclipse/handlers/EclipseHandlerUtil.java index 328a8e6d..5fd4c041 100644 --- a/src/core/lombok/eclipse/handlers/EclipseHandlerUtil.java +++ b/src/core/lombok/eclipse/handlers/EclipseHandlerUtil.java @@ -1014,8 +1014,8 @@ public class EclipseHandlerUtil { parent.fields[0] = field; } else { FieldDeclaration[] newArray = new FieldDeclaration[parent.fields.length + 1]; - System.arraycopy(parent.fields, 0, newArray, 0, parent.fields.length); - newArray[parent.fields.length] = field; + System.arraycopy(parent.fields, 0, newArray, 1, parent.fields.length); + newArray[0] = field; parent.fields = newArray; } |