Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

Hide snythetic lambda stack frames on debugger stacks

Đang mở
#9,673 12 bình luận 0 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 1 ngày

Chưa có ai nhận issue này.

Đánh giá

Độ khó
3/5
Thời gian dự kiến
1-2 ngày
Mức phù hợp với người mới
68/100
Loại issue
Lỗi
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
java
Lĩnh vực
devtools

Hướng nghiên cứu

Start from the stack trace: org.netbeans.modules.debugger.jpda.ui.values.ComputeInlineValues.computeVariables (line 41) feeds a frame's line number into javac's Position.getPosition, which throws when the frame is a synthetic lambda with no line number. Read ComputeInlineValues.java and InlineValueComputerImpl.java to see where frames are collected and where a no-line-number guard belongs; check whether the maintainer's comment thread already decides between hiding such frames vs. guarding the lookup. Done means clicking a lambda frame no longer logs ArrayIndexOutOfBoundsException and synthetic frames are either skipped or handled safely, verified with the sample snippet in the issue.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

debugger Java
    private static <V> V foo(Callable<V> call) throws Exception {
        return call.call();
    }

    static void main() throws Exception {
        foo(() -> {
            return null; // set breakpoint
        });
    }

trying to get to the marked stack frame causes an exception, should we hide frames without line numbers?

Image
SEVERE [org.openide.util.Exceptions]
java.lang.ArrayIndexOutOfBoundsException: Index -2 out of bounds for length 22
	at com.sun.tools.javac.util.Position$LineTabMapImpl.getPosition(Position.java:278)
	at com.sun.tools.javac.util.Position$LineMapImpl.getPosition(Position.java:193)
	at com.sun.tools.javac.util.Position$LineTabMapImpl.getPosition(Position.java:253)
	at org.netbeans.modules.debugger.jpda.ui.values.ComputeInlineValues.computeVariables(ComputeInlineValues.java:41)
	at org.netbeans.modules.debugger.jpda.ui.models.InlineValueComputerImpl$ComputeInlineVariablesFactory$1.run(InlineValueComputerImpl.java:355)
	at org.netbeans.modules.debugger.jpda.ui.models.InlineValueComputerImpl$ComputeInlineVariablesFactory$1.run(InlineValueComputerImpl.java:332)
[catch] at org.netbeans.modules.java.source.JavaSourceAccessor$CancelableTaskWrapper.run(JavaSourceAccessor.java:273)
	at org.netbeans.modules.parsing.impl.TaskProcessor.callParserResultTask(TaskProcessor.java:561)
	at org.netbeans.modules.parsing.impl.TaskProcessor$RequestPerformer.run(TaskProcessor.java:786)
	at org.openide.util.lookup.Lookups.executeWith(Lookups.java:288)
	at org.netbeans.modules.parsing.impl.TaskProcessor$RequestPerformer.execute(TaskProcessor.java:702)
	at org.netbeans.modules.parsing.impl.TaskProcessor$CompilationJob.run(TaskProcessor.java:663)
	at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:545)
	at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:330)
	at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:1370)
	at org.netbeans.modules.openide.util.GlobalLookup.execute(GlobalLookup.java:45)
	at org.openide.util.lookup.Lookups.executeWith(Lookups.java:287)
	at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:1981)

cc @lahodaj

Ngôn ngữ chính
Java
Star
3.1k
Fork
939
Merge trung bình
4 ngày 20 giờ
Pull request đã merge (30 ngày)
25

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của apache/netbeans

Tất cả issue của apache/netbeans

Issue tương tự

Thêm issue về Java

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.