Identifying Syntactic Differences between Two Programs
W. Yang. Software - Practice and Experience, 21 (7):
739-755(July 1991)
Abstract
Programmers frequently face the need to identify the differences between two programs, usually two different versions of a program. Text-based tools such as the UNIX utility diff often produce unsatisfactory comparisons because they cannot accurately pinpoint the differences and because they sometimes produce irrelevant differences. Since programs have a rigid syntactic structure as described by the grammar of the programming language in which they are written, we develop a comparison algorithm that exploits knowledge of the grammar. The algorithm, which is based on a dynamic programming scheme, can point out the differences between two programs more accurately than previous text comparison tools. Finally, the two programs are pretty-printed ‘synchronously’ with the differences highlighted so that the differences are easily identified.
%0 Journal Article
%1 Yang1991
%A Yang, Wuu
%D 1991
%J Software - Practice and Experience
%K algorithm code development diff matching paper read:2008 tree
%N 7
%P 739-755
%T Identifying Syntactic Differences between Two Programs
%V 21
%X Programmers frequently face the need to identify the differences between two programs, usually two different versions of a program. Text-based tools such as the UNIX utility diff often produce unsatisfactory comparisons because they cannot accurately pinpoint the differences and because they sometimes produce irrelevant differences. Since programs have a rigid syntactic structure as described by the grammar of the programming language in which they are written, we develop a comparison algorithm that exploits knowledge of the grammar. The algorithm, which is based on a dynamic programming scheme, can point out the differences between two programs more accurately than previous text comparison tools. Finally, the two programs are pretty-printed ‘synchronously’ with the differences highlighted so that the differences are easily identified.
@article{Yang1991,
abstract = {Programmers frequently face the need to identify the differences between two programs, usually two different versions of a program. Text-based tools such as the UNIX utility diff often produce unsatisfactory comparisons because they cannot accurately pinpoint the differences and because they sometimes produce irrelevant differences. Since programs have a rigid syntactic structure as described by the grammar of the programming language in which they are written, we develop a comparison algorithm that exploits knowledge of the grammar. The algorithm, which is based on a dynamic programming scheme, can point out the differences between two programs more accurately than previous text comparison tools. Finally, the two programs are pretty-printed ‘synchronously’ with the differences highlighted so that the differences are easily identified.},
added-at = {2008-05-30T16:17:33.000+0200},
author = {Yang, Wuu},
biburl = {https://www.bibsonomy.org/bibtex/246079344ac78b81d41ee0f10b837d76f/cschenk},
interhash = {d458465c8d4efa4254059c492741327b},
intrahash = {46079344ac78b81d41ee0f10b837d76f},
journal = {Software - Practice and Experience},
keywords = {algorithm code development diff matching paper read:2008 tree},
month = {July},
number = 7,
pages = {739-755},
timestamp = {2008-05-30T16:17:33.000+0200},
title = {Identifying Syntactic Differences between Two Programs},
volume = 21,
year = 1991
}