API for language syntax

Roman 8 years ago updated 8 years ago 1
Regexes cannot handle complex language constructs. Parser would be a much better match in many situations. 

One example may be support for nested block comments.

Please provide an API to allow hooking external parser to process language syntax (determine scopes).

Implementation details may vary, but it is important to have some solution for cases when regex is not appropriate. For example, this could be done similarly to API-injected completions.
This feature would also make possible semantic highlighting.