Finding differences between two Prolog files

Author(s): Francisco Bueno.

This simple program works like the good old diff but for files that contain Prolog code. It prints out the clauses that it finds are different in the files. Its use avoids textual differences such as different variable names and different formatting of the code in the files.

Usage (pldiff)

   
	pldiff <file1> <file2>
	   : find differences 

	pldiff -h
	   : print this information

   

but you can also use the program as a library and invoke the predicate:

   pldiff( <filename> , <filename> )
   

Known bugs and planned improvements

  • Currently uses variant/2 to compare clauses. This is useful, but there should be an option to select the way clauses are compared, e.g., some form of equivalence defined by the user.