accept bracket snippet variables without default

This commit is contained in:
Pascal Kuthe 2023-03-19 22:06:29 +01:00 committed by Blaž Hrastnik
parent 47420db516
commit 85c9dbf603

View File

@ -388,6 +388,12 @@ fn variable<'a>() -> impl Parser<'a, Output = SnippetElement<'a>> {
default: None,
regex: None,
}),
// ${var}
map(seq!("${", var(), "}",), |values| SnippetElement::Variable {
name: values.1,
default: None,
regex: None,
}),
// ${var:default}
map(
seq!(