File tree Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Original file line number Diff line number Diff line change @@ -34,12 +34,19 @@ export class FortranFormattingProvider
3434 }
3535
3636 /**
37- * Use `fprettyfy ` to format a Fortran file.
37+ * Use `fprettify ` to format a Fortran file.
3838 *
3939 * @param document vscode.TextDocument document to operate on
4040 */
4141 private doFormatFprettify ( document : vscode . TextDocument ) {
4242
43+ // fprettify can only do FortranFreeFrom
44+ if ( document . languageId !== 'FortranFreeForm' ) {
45+ this . logger . logError ( `fprettify can only format FortranFreeForm, change
46+ to findent for FortranFixedForm formatting` ) ;
47+ return
48+ }
49+
4350 const formatterName : string = 'fprettify' ;
4451 let formatterPath : string = this . getFormatterPath ( ) ;
4552 // If no formatter path is present check that formatter is present in $PATH
You can’t perform that action at this time.
0 commit comments