microsoft / microsoft/vscode-java-debug

Function breakpoint on constructor does not work e.g. java.io.PrintStream#PrintStream

未关闭
#1,331 1 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

ai-triaged breakpoint bug feature request
主要语言
TypeScript
星标
591
派生
429
平均合并
1 天 9 小时
30 天内合并 PR
19

描述

Function breakpoint on constructor does not work using syntax like java.io.PrintStream#PrintStream . I can set function breakpoint on methods like java.io.PrintStream#println .

In any program set function breakpoint on constructor of a library class constructor such as java.io.PrintStream#PrintStream or even user class:

package p;

public class UC {
    public UC() {
        System.out.println("In UC CTOR"); // Function breakpoint p.UC#UC should work and stop here.
    }
    public static void main(String[] args) {
        UC uc = new UC();
    }
}

Set function breakpoint: p.UC#UC

Current Result

Both function breakpoints java.io.PrintStream#PrintStream and p.UC#UC for constructors don't work.

Expected Result

Function breakpoints on constructors should work.

Additional Informations

贡献指南

打开贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

调研方向

使用提供的 p.UC 示例和 java.io.PrintStream#PrintStream 断点重现该问题,并将它们与正常工作的 println 断点进行比较。跟踪 Java 调试器对构造函数名称的 function-breakpoint 处理,然后验证库构造函数断点和用户类构造函数断点都会在构造函数体处停止。

由索引模型根据 Issue 内容生成。

评估

技术栈
java, typescript, vscode
领域
devtools
Issue 类型
缺陷
难度
4/5
预计耗时
3-5 天
活跃度
停滞
描述清晰度
基本清楚
新手友好度
45/100

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。