In Sublime’s syntax testing, is there a way to assert that text is not specially matched by the syntax? For example, bar
in what follows.
A naive first thought is this. But that doesn’t work since every character in the file matches source.lang
, and so that assertion is effectively a no-op:
foo bar
# ^^^ keyword.lang
# ^^^ source.lang
Then there’s this:
foo bar
# ^^^ keyword.lang
# ^^^ source.lang -storage -support -entity -keyword -constant -string -comment
…which works, but is verbose and brittle when duplicated in multiple places. For a belt and braces approach there would need to be still more negated selectors in there, too.
What if there were something like this?
foo bar
# ^^^ keyword.lang
# ^^^ ONLY source.lang