New URL for NEMO forge!   http://forge.nemo-ocean.eu

Since March 2022 along with NEMO 4.2 release, the code development moved to a self-hosted GitLab.
This present forge is now archived and remained online for history.
Changeset 11767 for utils/developer/fortran.py – NEMO

Ignore:
Timestamp:
2019-10-23T11:58:19+02:00 (5 years ago)
Author:
nicolasmartin
Message:

Modify lexer to recognize all logical operators
Move punctuation rule at the end of 'core' token to make operator rule working on .and., .not. & .or.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • utils/developer/fortran.py

    r11766 r11767  
    8989            (r'(::)', Keyword.Declaration), 
    9090 
    91             (r'[()\[\],:&%;.]', Punctuation), 
    9291            # Intrinsics 
    9392            (words(( 
     
    148147            # Comparing Operators 
    149148            (r'\.(eq|ne|lt|le|gt|ge|not|and|or|eqv|neqv)\.', Operator.Word), 
    150         ], 
    151  
     149 
     150            # Punctuation 
     151            (r'[()\[\],:&%;.]', Punctuation), 
     152        ], 
    152153        'strings': [ 
    153154            (r'(?s)"(\\\\|\\[0-7]+|\\.|[^"\\])*"', String.Double), 
Note: See TracChangeset for help on using the changeset viewer.