feat: support passing in a Rust regex in the grammar dsl

This commit is contained in:
Amaan Qureshi 2025-01-06 01:54:38 -05:00
parent 4170f71dbc
commit 68e707eb4f
4 changed files with 35 additions and 4 deletions

View file

@ -31,6 +31,6 @@ module.exports = grammar({
comment: _ => /#.*/,
variable: _ => /[a-zA-Z]\w*/,
variable: _ => new RustRegex('(?i:[a-z])\\w*'),
},
});