Please use the Apache issue tracking system for new NetBeans issues ( !!
Bug 248385 - Improve support of Project Lombok's 'val'
Improve support of Project Lombok's 'val'
Product: java
Classification: Unclassified
Component: Editor
PC All
: P3 with 6 votes (vote)
Assigned To: Dusan Balek
Depends on:
  Show dependency treegraph
Reported: 2014-11-04 08:13 UTC by xwinus
Modified: 2017-05-21 16:35 UTC (History)
2 users (show)

See Also:
Issue Type: DEFECT

Example of code completion defect (12.05 KB, image/png)
2014-11-04 08:13 UTC, xwinus
screenshot showing lombok's val not working in netbeans (172.19 KB, image/png)
2016-11-03 15:41 UTC, jason3421
Lombok val feature not working on netbeans 8.2 (147.55 KB, image/png)
2017-05-21 16:35 UTC, pedrohidalgo

Note You need to log in before you can comment on or make changes to this bug.
Description xwinus 2014-11-04 08:13:48 UTC
Created attachment 150256 [details]
Example of code completion defect

Hello there,

one of the great features of Lombok Project is the possibility to use keyword 'val' for local variables, instead of defining their type ( When used in code, everything compiles right, however, the IDE code completion used on variable defined using this is incorrect (please see the attached image). Is it possible to fix this feature to show correct method completion list, based on real variable type?
Comment 1 Martin Balin 2016-07-07 07:17:17 UTC
This old bug may not be relevant anymore. If you can still reproduce it in 8.2 development builds please reopen this issue.

Thanks for your cooperation,
NetBeans IDE 8.2 Release Boss
Comment 2 jason3421 2016-11-03 15:41:16 UTC
Created attachment 162750 [details]
screenshot showing lombok's val not working in netbeans
Comment 3 jason3421 2016-11-03 15:43:57 UTC
The screenshot I just attached shows lombok's val support doesn't work in Netbeans Dev Version 2016110200002 (last night's development build). The maven build works, but the IDE improperly reports an error via the red squiggly underline which states: " error: incompatible types: int cannot be converted to val". To reproduce just follow the screenshot - create a new maven project, import lombok, create your public static void main, and use 'val'.
Comment 4 pedrohidalgo 2017-05-21 16:35:02 UTC
Created attachment 164369 [details]
Lombok val feature not working on netbeans 8.2

Same issue here:

NetBeans doesn't provide autocompletion on variable created using the Lombok's val feature, see screenshot attached:

Lombok 1.16.16
Netbeans 8.2 
Macos 10.12.5

By use of this website, you agree to the NetBeans Policies and Terms of Use. © 2014, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo