Linguist: Support for fixed form Fortran

Created on 2 Nov 2019  路  6Comments  路  Source: github/linguist

Preliminary Steps

Please confirm you have...

Problem Description

Comments in fixed form fortran are not properly highlighted

See https://github.com/bburns/rocket.f77/blob/master/rocket.f#L6-L51
and https://github.com/johannesgerer/jburkardt-f77/blob/master/asa032/asa032.f#L3-L34

Fixed form Fortran interprets lines with C,c, !, or * in the first column as comments.

The issue is not with the grammar, as selecting the proper grammar fixes the issue.

See https://github-lightshow.herokuapp.com/?utf8=%E2%9C%93&scope=from-url&grammar_format=auto&grammar_url=https%3A%2F%2Fgithub.com%2Ftextmate%2Ffortran.tmbundle%2Fblob%2Fmaster%2FSyntaxes%2FFortran%2520-%2520Punchcard.tmLanguage&grammar_text=&code_source=from-url&code_url=https%3A%2F%2Fgithub.com%2Fjohannesgerer%2Fjburkardt-f77%2Fblob%2Fmaster%2Fasa032%2Fasa032.f%23L3-L34&code=

As far as I know, I can only select linguist-language=fortran in .gitattributes.
I have no way to specify source.fortran rather than source.fortran.modern as grammar
since only source.fortran.modern is listed inside linguist/lib/linguist/languages.yml.

Most helpful comment

As soon as I make a release, which I'm hoping to do this or next week when I get some free time that coincides with a quiet deploy queue.

All 6 comments

Should we just use source.fortran instead of source.fortran.modern? That scope was set five years ago in 9acf41b0fea9eb0180224afb8f684967dc197e4e, so I doubt the author remembers why.

That seems to be fixed (great!). How long would it take for this change to take effect on GitHub ?

As soon as I make a release, which I'm hoping to do this or next week when I get some free time that coincides with a quiet deploy queue.

Do you think this release will fix the doxygen comment block highlight issue? It seems broken with fixed form Fortran here

This looks fixed to me by #4686 .

Was this page helpful?
0 / 5 - 0 ratings

Related issues

Alhadis picture Alhadis  路  5Comments

haskellcamargo picture haskellcamargo  路  3Comments

oliviertassinari picture oliviertassinari  路  5Comments

oldmud0 picture oldmud0  路  6Comments

TimothyGu picture TimothyGu  路  5Comments