Transferring Java Comments Based on Program Static Analysis.

Binger Li,Feifei Li,Xinlin Huang,Xincheng He,Lei Xu
DOI: https://doi.org/10.1007/978-3-030-30952-7_64
2019-01-01
Abstract:In the process of software development and maintenance, code comments can help developers reduce the time of reading source code, and thus improve their work efficiency. For large Java software projects, comments tend to appear in front of the main program entry or method definition. Readers need to search and read other source files containing the comments, which is very inconvenient. For this purpose, based on program static analysis technique, this paper has realized the process of automatically transferring comments in source code to their corresponding methods’ callers. This method first processes the source code using the program static analysis tool, which identifies the method call and the variable Define-Use and other dependency relations and confirms the comment-transferring paths; then extracts the text information in the comments that are in front of method definitions. Finally, it completes the extraction and transferring of comments in Java projects. The average precision of the experiment with 14 open source Java projects is 82.76%.
What problem does this paper attempt to address?