branch: scratch/yasnippet commit 2f751c3a0a5ea7df075a8460aeb3e82bd1500e9c Author: Stefan Monnier <monn...@iro.umontreal.ca> Commit: Stefan Monnier <monn...@iro.umontreal.ca>
* yasnippet.el (debug-ignored-errors): Don't modify it (debug-ignored-errors): Remove left over code that became obsolete with commit 175e0a3a102c22. (yas--read-lisp): Fix code generation. (yas-exception): Use `define-error`. --- yasnippet.el | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/yasnippet.el b/yasnippet.el index ce59d25a9a..c4f8ae48fa 100644 --- a/yasnippet.el +++ b/yasnippet.el @@ -1490,7 +1490,7 @@ return an expression that when evaluated will issue an error." (condition-case err (read string) (error (and (not nil-on-error) - `(error (error-message-string ,err)))))) + `(error (error-message-string ',err)))))) (defun yas--read-keybinding (keybinding) "Read KEYBINDING as a snippet keybinding, return a vector." @@ -3041,8 +3041,7 @@ snippet field. The arguments are the same as `completing-read'. (defun yas-throw (text) "Signal `yas-exception' with TEXT as the reason." (signal 'yas-exception (list text))) -(put 'yas-exception 'error-conditions '(error yas-exception)) -(put 'yas-exception 'error-message "[yas] Exception") +(define-error 'yas-exception "[yas] Exception") (defun yas-verify-value (possibilities) "Verify that the current field value is in POSSIBILITIES. @@ -3943,8 +3942,6 @@ Move the overlays, or create them if they do not exit." (cl-loop for snippet in snippets do (yas--commit-snippet snippet))))) -(add-to-list 'debug-ignored-errors "^Exit the snippet first!$") - ;;; Snippet expansion and "stacked" expansion: ;;