fix(snippets): yas-expand error on yas-choose-value (#5429)
`+snippets-prompt-private` was overzealous intercepting the candidates fed to `yas-choose-value`. For example, expanding the `jupyter` snippet in org mode results in: \#+begin_src jupyter-Wrong type argument: yas--template, "python" :session :async yes ... \#+end_src
This commit is contained in:
parent
25c7f347cb
commit
33e922645b
1 changed files with 3 additions and 1 deletions
|
@ -20,7 +20,9 @@ If there are conflicting keys across the two camps, the built-in ones are
|
|||
ignored. This makes it easy to override built-in snippets with private ones."
|
||||
(when (eq this-command 'yas-expand)
|
||||
(let* ((gc-cons-threshold most-positive-fixnum)
|
||||
(choices (cl-remove-duplicates choices :test #'+snippets--remove-p)))
|
||||
(choices (condition-case _
|
||||
(cl-remove-duplicates choices :test #'+snippets--remove-p)
|
||||
(wrong-type-argument choices))))
|
||||
(if (cdr choices)
|
||||
(cl-loop for fn in (cdr (memq '+snippets-prompt-private yas-prompt-functions))
|
||||
if (funcall fn prompt choices display-fn)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue