CSeR (Code Segment Reuse)

Date:

Tool support for managing code clones plays a crucial role in improving software quality and maintainability. While extensive research has focused on detecting clones in existing source code, there has been comparatively less attention on proactively tracking and supporting copy–paste–modify operations, even though such actions are a major source of clone creation and evolution.

To address this gap, we designed and implemented CSeR (Code Segment Reuse)—a programming editor built on the Eclipse IDE. CSeR maintains a record of copy-and paste-induced clones and tracks subsequent modifications, visually highlighting differences using distinct colors for better comprehension.

At its core, CSeR features a unique edit-based comparison algorithm that actively analyzes two related clones as they are being edited. This approach delivers more immediate, accurate, and intuitive results than traditional differencing tools, making it a valuable asset for software developers seeking better clone management and code consistency.

Slides