draivin/hsnips

Tabstop information is lost when using nested snippets

Opened this issue · 1 comments

Say I have these snippets:

snippet $$$ "inline Math" iA
$ $1 $``
let test = t[1][0];
console.log(t)
if (test === undefined) {
  rv = '';
}
else if (test == ':' || test == ',' ||  test == '.' || test =='?' || test ==' ' || test =='-'){
	rv = '';
}
else{
	rv = ' ';
}``$2
endsnippet

snippet tt "test" wA
text $1 after
endsnippet

And I trigger the test snippet inside the $$$ snippet. When I trigger the snippet, the content is added to the t-array. But after that, the content is no longer updated, and therefore "outer" snippets possibly don't work as intended anymore. See image for console output (I typed more after inserting the snippet, but no updates):
grafik

Strangely though it does keep the information if I enter nothing in the first tabstop and just move on to the next:

grafik

This also happens with all extensions disabled and has nothing to do with the VSCodeVim extension.