debug info inside lambda body

Brian Goetz brian.goetz at oracle.com
Mon Oct 7 08:08:24 PDT 2013


I think this is a straightforward omission.  I have filed:
   https://bugs.openjdk.java.net/browse/JDK-8025998

On 10/7/2013 10:21 AM, Anna Kozlova wrote:
> Hi guys,
>
>
>
> we try to make the debugger work inside lambda body. As far as we can see
> there is no local variable table generated for the method into which the
> lambda was compiled.
>
> E.g. for a lambda
>
>         Runnable r = () -> {
>
>              int i = 0;
>
>          };
>
>
>
> Generated bytecode is as following
>
>
>
> // access flags 0x100A
>
>    private static lambda$0()V
>
>     L0
>
>      LINENUMBER 1 L0
>
>      ICONST_0
>
>      ISTORE 0
>
>     L1
>
>      LINENUMBER 46 L1
>
>      RETURN
>
>      MAXSTACK = 1
>
>      MAXLOCALS = 1
>
>
>
> Because of that our debugger can't access local variable information through
> JDI API. Was that intentional decision or will it be changed later?
>
>
>
> Thank you
> Anna Kozlova
> JetBrains
>   <http://www.intellij.com/> http://www.jetbrains.com
> "Develop with pleasure!"
>
>
>
>


More information about the lambda-dev mailing list