The FTN95 can do that itself by pre-processing the source code with and without /free or /fixed . It is doing that very fast as only beginning 10-20 errors will stop it.
If the file is fixed form but compiled as /free FTN95 gives many errors with diagnostics like
*** Invalid character '*' at start of line, statement not recognised
and if free format source compiled as fixed format source it gives errors like
*** Invalid characters in label field of FIXED format source, Statement not recognised
Other indicators -
- columns 1 through 5 are reserved for statement labels for fixed format and not for free
- letter C or an * placed in column 1 indicates that the statement is a comment for fixed and give error with /free
- words continuing after 72th character are for /free unless there is no restriction with 72 characters are given with special compilation key
- continuations of free format source end with &
etc also give the clue if this is fixed source or free one. The simplest 30 minutes program which checks 1) and 2) already gives 99% chance that the source code is identified, all 4 will give 99.99%. This is not a self-driving AI problems like in Tesla electric car π
If problem will occur, and they will with not yet debugged code, or text is too small (like just one line Hello World) the preprocessor may ask the user: 'The text too small, has non-standard syntax or not yet fully debugged, with probability 98% it looks like a fixed format source. Do you agree to treat it as fixed one?'
Other approach is to use Metcalf's converter from fixed to free format source code for it is freely available. Preprocessing fortran source with it but without real conversion and just counting in how many lines it had similar troubles like FTN95 above had, will also tell if this is actually fixed source or not
https://people.math.sc.edu/Burkardt/f_src/f77_to_f90/f77_to_f90.f90
Ones Mecej4 gave me the program which extracts snippets out of large code. It preprocessed the source code with much larger details than i even know. And you also know much more than me in these matters
This human-computer communication with the user will make Plato simpler and more enjoyable to work with. Answering its Yes No is simpler than digging inside and trying to find where the hell is this or that settings