lishunli / projectlombok

Automatically exported from code.google.com/p/projectlombok
0 stars 0 forks source link

Renaming field and generated getter also "renames" annotation #533

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
From: issue 527

See also issue 286, issue 316.

Renaming a field and its generated getter also change the @Getter annotation to 
the new getter value.

Have
  @Getter int foo;

Press Alt-Shift-R, R to bring up the rename dialog
Change foo to bar

  @getBar int bar;

Original issue reported on code.google.com by askon...@gmail.com on 13 Jun 2013 at 7:54

GoogleCodeExporter commented 9 years ago

Original comment by askon...@gmail.com on 13 Jun 2013 at 7:57

GoogleCodeExporter commented 9 years ago
Eclipse 3.7.2
Lombok v1.12.4 (January 15th, 2014)

Similar problem with generic class:

public class LombokTest<T> {
    @Getter
    @Setter
    private T field;
}

Result of renaming T to XYZ:

public class LombokTest<XYZ> {
    XYZ
    XYZ
    private XYZ field;
}

Original comment by andras.f...@eyan.eu on 1 Sep 2014 at 11:28