2006-06-01 21:23:28 +04:00
|
|
|
## Here is an example for assembler.
|
2014-05-17 00:21:34 +04:00
|
|
|
|
2018-02-07 13:25:46 +03:00
|
|
|
syntax asm "\.(S|s|asm)$"
|
2017-11-19 13:10:53 +03:00
|
|
|
magic "assembler source"
|
2016-05-25 23:13:50 +03:00
|
|
|
comment "//"
|
2014-05-17 00:21:34 +04:00
|
|
|
|
2006-06-01 21:23:28 +04:00
|
|
|
color red "\<[A-Z_]{2,}\>"
|
|
|
|
color brightgreen "\.(data|subsection|text)"
|
|
|
|
color green "\.(align|file|globl|global|hidden|section|size|type|weak)"
|
|
|
|
color brightyellow "\.(ascii|asciz|byte|double|float|hword|int|long|short|single|struct|word)"
|
2019-08-17 18:01:19 +03:00
|
|
|
color brightred "^[[:space:]]*[.0-9A-Za-z_]*:"
|
2006-06-01 21:23:28 +04:00
|
|
|
color brightcyan "^[[:space:]]*#[[:space:]]*(define|undef|include|ifn?def|endif|elif|else|if|warning|error)"
|
2014-05-17 00:21:34 +04:00
|
|
|
|
|
|
|
# Strings.
|
2006-06-01 21:23:28 +04:00
|
|
|
color brightyellow "<[^= ]*>" ""(\\.|[^"])*""
|
2015-12-29 19:48:25 +03:00
|
|
|
# Multiline strings. This regex is VERY resource intensive,
|
|
|
|
# and sometimes colours things that shouldn't be coloured.
|
|
|
|
###color brightyellow start=""(\\.|[^"])*\\[[:space:]]*$" end="^(\\.|[^"])*""
|
2014-05-17 00:21:34 +04:00
|
|
|
|
|
|
|
# Comments.
|
2006-06-01 21:23:28 +04:00
|
|
|
color brightblue "//.*"
|
|
|
|
color brightblue start="/\*" end="\*/"
|
2014-05-17 00:21:34 +04:00
|
|
|
|
|
|
|
# Trailing whitespace.
|
2007-04-12 02:18:16 +04:00
|
|
|
color ,green "[[:space:]]+$"
|