"Let's model me a mine"
M.E.G.M.S.
Mining & Exploration Geological Modelling Services
FF08Diff is a command line tool for obtaining the semantic difference (difference in meaning, rather than appearance) between two sets of Fortran 2008 source files.
The tool itself is written in Fortran 2003. A zip archive of the latest source release (revision 3189 from 2024-08-12), available under an Apache 2.0 licence, can be found at www.megms.com.au/download/FF08Diff.zip.
The command line has the following syntax:
FF08Diff [options] source-file-specs... [--right source-file-specs...]
Command line options:
source-file-specs is a list of the names of the Fortran source files to parse.
If neither --left or --right is specified, then there must only be two source-file-specs that each evaluate to a single source filename, the first filename becomes the left source set and the second filename becomes the right file set. Alternatively, there can be two --list options - the first specifies the files for the left set, the second for the right set.
Source files with an extension (part of the filename following the last dot) of for or f are taken to be fixed source form files. Source files with an extension of f90, f95, f03 or f08 are taken to be free source form. Other extensions result in an error. The comparison with the file extension is not case sensitive.
Differencing is not sensitive to:
As the differencing looks at the semantics of the source code, it requires the source code to be Fortran 2008 standard conforming, to the degree sufficient for the program to understand the intended semantics. This particularly includes structural aspects of the source, such as matching beginning and end statements for any constructs.
Differences are reported to the console. Errors encountered during differencing are reported to the error unit.
Each difference is typically reported using three records (lines):
STOP codes (which may also be the program's exit code):
Compare two source files.
FF08Diff left.f90 right.f90
Compare two sets of files, with the left set specified by a list file and the right set explicitly listed.
FF08Diff --list: left-list-file.txt --right file1.f90 file2.f90
The source code should be compilable by a Fortran 2003 compiler.
Intel Visual Fortran 15.0 was the compiler used for development. With that compiler, the /standard-semantics switch (or its equivalent on non-Windows platforms) is required.
The file compile-order.txt in the source archive specifies the order in which the included source files may be compiled.
Note that gfortran current trunk (at the time of writing r238060) cannot be used due to PR 44265, PR 71796 and PR 71807.
Questions, queries and quibbles can be sent to ff08@megms.com.au.