[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] master 572c73d 7/8: Avoid error in case this-command isn't a symb
From: |
João Távora |
Subject: |
[elpa] master 572c73d 7/8: Avoid error in case this-command isn't a symbol. |
Date: |
Mon, 07 Mar 2016 08:50:58 +0000 |
branch: master
commit 572c73d50b5521b4a56eae7b00ae6c7e61582e06
Author: Noam Postavsky <address@hidden>
Commit: Noam Postavsky <address@hidden>
Avoid error in case this-command isn't a symbol.
Fixes #664.
* yasnippet.el (yas--skip-and-clear-field-p): Only get
`delete-selection' property of `this-command' when it's a symbol.
---
yasnippet.el | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/yasnippet.el b/yasnippet.el
index 69d6b26..b68389f 100644
--- a/yasnippet.el
+++ b/yasnippet.el
@@ -3390,9 +3390,9 @@ BEG, END and LENGTH like overlay modification hooks."
(= (point) (yas--field-start field))
(require 'delsel)
;; `yank' sets `this-command' to t during execution.
- (let ((clearp (get (if (commandp this-command) this-command
- this-original-command)
- 'delete-selection)))
+ (let* ((command (if (commandp this-command) this-command
+ this-original-command))
+ (clearp (if (symbolp command) (get command 'delete-selection))))
(when (and (not (memq clearp '(yank supersede kill)))
(functionp clearp))
(setq clearp (funcall clearp)))
- [elpa] master updated (ab7d7f3 -> 9983491), João Távora, 2016/03/07
- [elpa] master 4a6d923 1/8: Slightly improve on fix for #515: Refactor code and add tests, João Távora, 2016/03/07
- [elpa] master acf2cdd 2/8: Decide field clearing commands based on delsel, João Távora, 2016/03/07
- [elpa] master 80941c0 3/8: Update snippets submodule, João Távora, 2016/03/07
- [elpa] master 42601d2 4/8: Apply changes from GNU ELPA, João Távora, 2016/03/07
- [elpa] master 8632262 5/8: Don't use yas-x-prompt by default, João Távora, 2016/03/07
- [elpa] master 88b7950 6/8: Reduce `yas-new-snippet-default', João Távora, 2016/03/07
- [elpa] master 572c73d 7/8: Avoid error in case this-command isn't a symbol.,
João Távora <=
- [elpa] master 9983491 8/8: Update packages/yasnippet by subtree-merging from its github-based upstream, João Távora, 2016/03/07