Honza-cz commented on issue #6311:
URL: https://github.com/apache/netbeans/issues/6311#issuecomment-1771621368

   I fought with code base to be able to extract lambda expression with {} but 
I failed. 
   
   If I extract ` return t + text + m1;`
   
   from
   ```
   private int dummy(final String text) {
       Function<String, String> test2 = t -> {
           return t + text + m1;
       };
   
       return test2.apply(text).length();
   }
   ```
   
   Netbeans wrongly deduct the return type from method, whic int:
   ```
   private int dummy(final String text) {
       Function<String, String> test2 = t -> {
           return inner(t, text);
       };
   
       return test2.apply(text).length();
   }
   
   private int inner(String t, final String text) {
       return t + text + m1;
   }
   ```
   
   I haven't found a way how to make it working so far :(


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists

Reply via email to