ultisnips
ultisnips copied to clipboard
Nested one-line snippets work abnormally
Actual behavior:
Related snippets
snippet '(?a)\blm' "行内公式 Inline Formula" Ar
$$1$ $0
endsnippet
snippet case "Cases 环境 Cases Environment" w
\begin{cases} $1 \end{cases} $0
endsnippet
That is, sometimes* the cursor will select the outer placeholder if inner placeholders are jumped out.
*: Sometimes it works normally.
Besides, if snippets are multi-line snippets, it seems to work normally.
For example
snippet dm "行间公式 Display Formula" Ab
$$
$1
$$
$0
endsnippet
snippet case "Cases 环境 Cases Environment" w
\begin{cases}
${1:${VISUAL}}
\end{cases}
$0
endsnippet
Maybe related to the situation 3 of #1472?
Steps to reproduce
- Add above snippets
- Type as the GIF demonstrates
- Then sometimes it will work abnormally like this
- Operating System: Windows 10
- Vim Version: 9.0
- UltiSnips Version: 3.2
- Python inside Vim: 3.10.4