Designing and evaluating an intention-based comment enforcement scheme for Java

Matz, Kevin (2010). Designing and evaluating an intention-based comment enforcement scheme for Java. Student dissertation for The Open University module M801 MSc in Software Development Research Dissertation.

Please note that this student dissertation is made available in the format that it was submitted for examination, thus the author has not been able to correct errors and/or departures from academic standards in areas such as referencing.

DOI: https://doi.org/10.21954/ou.ro.00016093

Abstract

Software maintenance forms a significant portion of the cost of large-scale software projects. A time-consuming part of maintenance is program comprehension – reading legacy code to understand how and where to make changes. The process of understanding existing code involves reconstructing the design intentions and rationale of the original developers. This dissertation argues that explicitly recording intention and rationale information during design and construction eases program comprehension during maintenance. This dissertation conducts a survey of practicing software developers to understand difficulties in software maintenance and opinions on software documentation. The results and a literature survey are then used to argue that significant problems exist which can best be dealt with by designing a new technology-based solution. By reviewing the program comprehension literature and examining past solutions, requirements are formulated for an “ideal” solution for recording intention and rationale documentation. A partial solution, Design Intention Driven Programming, is proposed, which encourages developers to record design intentions before writing code. The process is supported by a language, Java with Intentions, which adds intention comments, first-class documentation constructs, to the Java language. The compiler flags as errors any artefacts (e.g., classes) not described by intention comments and uses complexity metrics to detect “empty” comments. A rudimentary prototype of a precompiler for the language and a sample application are constructed as proofs of concept. The solution is evaluated using several analyses and by surveying developers for feedback on its practicality. Respondents’ opinions are divided on the solution’s feasibility and utility. Numerous problematic issues are identified, including resistance of developers to write documentation, limitations of the documentation enforcement mechanism, and the lack of concrete evidence of long-term cost savings. The evaluation suggests that, while the approach may be promising for some projects and teams, its unpopularity with most developers renders it impractical for typical commercial projects.

Viewing alternatives

Download history

Metrics

Public Attention

Altmetrics from Altmetric

Number of Citations

Citations from Dimensions

Item Actions

Export

About