Hi Andre,
it came up in a previous issue that some default values for language definitions don't show up when debugging with verbose:
I've tried defining Escape as an empty string, but this caused bad parsing behavior. It seems that
Highlight has some internal default definition of Escape string, but it doesn't show up in the --verbose output.
There is a default regex (will check why it is not displayed).
Today I was doing some tests with a bare-bone langDef (just Description and a Keywords entry) to actually check which elements have defaults and what these are. As it came out, the only visible defaults I can see via --versose are these two:
Digits (string = [ (?:0x|0X)[0-9a-fA-F]+|\d*[\.]?\d+(?:[eE][\-\+]\d+)?[lLuU]* ])
Identifiers (string = [ [a-zA-Z_]\w* ])
I somehow have the impression that the debug is not showing all the defaults --- Escape, as mentioned in the quote, but possibly others.
Also, boolean definitions don't show up (IgnoreCase, EnableIndentation, etc.). Are these hidden because false or null by default?
The documentation only mentions two default settings:
Global variables:
The following variables are available within a language definition:
HL_LANG_DIR: path of language definition directory (use with Lua dofile function)
Identifiers: Default regex for identifiers
Digits: Default regex for numbers
... so it might be correct. But, as mentioned in issue #23, even if I don't define Escapes Highlight seems to catch C-style escape sequences nonetheless (so I guess there is a hidden default string somewhere).
NOTE: This came up while I was working on PR #34