paperbot · PL 论文追踪

全部论文 待读 收藏

P2 Understanding Code Fragments with Issue Reports

利用 issue 报告理解代码片段
ASE 2021 36th IEEE/ACM International Conference on Automated Software Engineering (ASE)2021匹配度 3/10 · 该论文关注程序理解与代码注释生成,通过关联代码片段和 issue 报告解释维护意图,属于软件工程/开发者工具方向;但未涉及静态分析、LLM/Agent、浮点程序分析或贝叶斯程序分析,与研究画像的核心问题关联较弱。引用 3 inbox
Zexuan Li, Hao Zhong
crossref: 2026-09-12

AI 速览

一句话:提出 ISSUECOMM,将代码片段与 issue 报告关联,为理解代码维护意图提供补充注释。

代码注释对软件开发与维护至关重要。现有注释生成方法主要利用编程经验、源码中的代码-注释对以及相似代码片段的注释,多解释代码“做什么”,却很少解释代码“为何如此开发”。本文引入 issue 报告作为新信息源,其中包含维护类型、症状和修改目的等丰富信息。作者提出首个方法 ISSUECOMM,自动建立代码片段与 issue 报告之间的链接。实验表明,该方法能关联程序员在注释中写出的 70% 以上 issue 编号,且其链接覆盖的 bug 数量是人工注释的 4 倍,其他 issue 数量是人工注释的 10 倍。文中还通过样例说明这些链接有助于描述代码功能与开发目的。

问题
现有代码注释生成主要解释代码功能,缺少说明代码为何以特定方式开发的信息,而人工注释对 issue 的覆盖又很有限。
方法
提出 ISSUECOMM,以 issue 报告为新信息源,自动建立代码片段与 issue 报告之间的链接,从而辅助理解代码的维护背景与目的。
评估
实验显示该方法能关联程序员在注释中写出的 70% 以上 issue 编号,且链接覆盖的 bug 数是人工注释的 4 倍、其他 issue 数是 10 倍,并通过样例展示其有用性。
原文摘要(Abstract)

Code comments are vital for software development and maintenance. To supplement the code comments, researchers proposed various approach that generate code comments. The prior approaches take three sources: (1) programming experience, (2) code-comment pairs in source files, and (3) comments of similar code snippets. Most of their generated comments explain code functionalities, but programmers also need comments that explain why a code fragment was developed as it is. To meet the timely needs, in this paper, we introduce a new source, issue reports (e.g. maintenance types, symptoms, and purposes of modifications), to generate code comments. Issue reports contain rich information on how code was maintained. The valuable details of issue reports are useful to understand source code, especially when programmers learn why code was developed in a specific way. Towards this research direction, we propose the first approach, called ISSUECOMM, that builds the links between code fragments and issue reports. Our results show that it links more than 70% issue numbers that are written by programmers in code comments. Furthermore, the links built by our tool covers 4× bugs, and 10× other issues than the links written in manual comments. We present samples of our built links, and explain why our links are useful to describe the functionalities and the purpose of code.

链接与引用

DOI 原文 ·

BibTeX
@inproceedings{paperbot6565,
  title = {Understanding Code Fragments with Issue Reports},
  author = {Zexuan Li and Hao Zhong},
  booktitle = {ASE},
  year = {2021},
  doi = {10.1109/ase51524.2021.9678864}
}