ffscan1
Checks argument count for fortran f77 files
Usage
ffscan [-fhnqv]
-Eext
-Idir
-ofile
-xname
[files]
Overview
ffscan scans a collection of fortran files and checks the argument counts of every call made against its definition. When a mismatch occurs, ffscan will tell you in which file this particular call is made, and it will also tell what the correct number of arguments should be, together with the name of the file where the subroutine in question can be found. ffscan does not do any type checking on the arguments, it simply counts them.
Options
-
-f -
Include the full path of files in the output. The default is to print the name of the file only. Using this option increases the memory
ffscanuses to store its data, so it might be unwise to use this option on msdos systems with their 640kb memory limit.
-
-h, --help -
print a short help describing the options.
-
-n, -n- -
Using this option will cause
ffscanto tell what subroutines are never invoked.
-
-q -
be really quiet (usefull if called from a script). Only error messages and the final results will be shown.
-
-v -
Be verbose. Adding more -v to the command line will increase the output
ffscanwill generate.Using
-vwill show some statistics of the files being scanned such as the number of subroutines and functions defined in a file and the number of calls made. If you use the-ofile option, these statistics will also be placed in fileUsing
-vvwill, in addition to the output mentioned above, causeffscanto report all settings it is using to determine what files it has to scan.When you use
-vvvffscanwill tell you what it is scanning from your files, this in addition to the output mentioned above. For each subroutine, function or call it encounters,ffscanwill tell you what the name of that routine is and the arguments detected. It will also tell you how many arguments there are. A number called brace count is also shown. This number should always be zero. Using this option can generate a considerable amount of output, so you might wish to pipe it to a file.At the end of a run
ffscanwill also give a count for the total number of subroutines and functions found.
-
--version -
Show the version number of
ffscan
-
-Eext -
Extensions
ffscanmust use to determine which files it has to scan. Up to eight -E are allowed. The default extension is .f
-
-Idir -
Using this option tells
ffscanwhich directories it has to search for f77 files. Only the contents of that directory are scanned. Subdirectories are ignored. Up to 64 -I are allowed.
-
-ofile -
file in which to store the results of the scan. The default is stdout.
-
-xname -
Tells
ffscanto exclude the named file when scanning the files found with the -I -E options. Up to 64 -x are allowed.
Diagnostics
The following warning messages can occur:
- WARNING: unbalanced right brace
- WARNING: unbalanced left brace
-
When one of these warnings occur, you have a brace to many or a missing brace in the argument list of a subroutine or function definition or in the argument list of a call.
- WARNING: more than 19 contination lines
-
ffscanhas detected more than 19 successive continuation lines in a argument declaration.
- WARNING: no program entry point found
-
a call statement was encountered before a PROGRAM statement was found.
ffscanwill use the name of the file where this warning occurs as a program name and continue.ffscanwill always tell you in which file and around what line these warnings occur.
Distribution policy
All utilities in this fortran utility suite are distributed under the GNU Public License.
Compatibility
ffscan has run under HP-UX 9 and 10, SGI IRIX 5.2 & 5.3, DEC OSF1, SunOs 4.1 and 4.3, Cray Unicos, IBM AIX 3.2 & 4.1, Linux and MSDOS 6.2. ffscan also runs in a dos box under Windows 3.1, 3.11 and Win95.
Shortcomings
Currently, ffscan only looks at CALL, so although FUNCTION is found, these are not checked.
Releases
Unchanged in 4 releases since Debian 3.0 (Woody).