2006-06-01 17:23:28 +00:00
|
|
|
## Here is an example for assembler.
|
2014-05-16 20:21:34 +00:00
|
|
|
|
2018-02-07 10:25:46 +00:00
|
|
|
syntax asm "\.(S|s|asm)$"
|
2017-11-19 10:10:53 +00:00
|
|
|
magic "assembler source"
|
2016-05-25 20:13:50 +00:00
|
|
|
comment "//"
|
2014-05-16 20:21:34 +00:00
|
|
|
|
2006-06-01 17:23:28 +00: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)"
|
|
|
|
icolor brightred "^[[:space:]]*[.0-9A-Z_]*:"
|
|
|
|
color brightcyan "^[[:space:]]*#[[:space:]]*(define|undef|include|ifn?def|endif|elif|else|if|warning|error)"
|
2014-05-16 20:21:34 +00:00
|
|
|
|
|
|
|
# Strings.
|
2006-06-01 17:23:28 +00:00
|
|
|
color brightyellow "<[^= ]*>" ""(\\.|[^"])*""
|
2015-12-29 16:48:25 +00: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-16 20:21:34 +00:00
|
|
|
|
|
|
|
# Comments.
|
2006-06-01 17:23:28 +00:00
|
|
|
color brightblue "//.*"
|
|
|
|
color brightblue start="/\*" end="\*/"
|
2014-05-16 20:21:34 +00:00
|
|
|
|
|
|
|
# Trailing whitespace.
|
2007-04-11 22:18:16 +00:00
|
|
|
color ,green "[[:space:]]+$"
|