-
Notifications
You must be signed in to change notification settings - Fork 80
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
OMP lines are not recognized #12
Comments
OMP lines would appear to be compiler instructions that would only apply to certain users. So the first step is to find a good specification of their structure so we can determine if they would conflict for people that weren't using that variant. |
All Fortran compilers that supports OMP interprets the OMP lines as standard (you actually have to supply a compiler option to disable it) and would issue an error if a line starting with "!$" is not a valid OMP instruction. |
Actually, i just noticed that 'subroutines' are not recognized either. In my opinion, subroutines should be recognized in exactly the same manner as functions. |
The biggest issue when I've had to edit the grammar in the past is finding the language specifications for various parts of the grammar, do you have any pointers to that for subroutines? |
See, I'm not actually sure what you mean by grammar in this context. If you mean how the syntax of a subroutine is, it is actually the same syntax as for functions, i.e., like the following: subroutine subroutine_name(argument1,argument2,...,argumentn)
! Declarations here
real, dimension(:) :: argument1
integer :: argument2, ..., argumentn
! Code here
argument2 = 2*argumentn
end subroutine Where I use "..." to emphasize that there may be many arguments. |
Sorry for the gap here, don't get around to this bundle very often. Subroutines appear to be highlighted correctly here best I can tell. (As you can tell from your code example as Github uses this grammar for matching.) When I was talking about the language spec I was talking about the OMP lines, need some sort of language spec to know how to match them. Fortran is a very hard language to work on as there are several different and conflicting standards to deal with each time I update or change anything. |
OMP specific lines are not recognized. They begin with "!$" and are stylized like comments, which only start with "!".
OMP specific lines should be formatted differently than comments. Otherwise they are very hard to spot.
Is there anything I can do to fix the problem?
I have included an example of the problem below.
The text was updated successfully, but these errors were encountered: