[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] master e23a053 34/36: Avoid bug in insert-file-contents with REPL
From: |
Noam Postavsky |
Subject: |
[elpa] master e23a053 34/36: Avoid bug in insert-file-contents with REPLACE=t |
Date: |
Sat, 11 Jun 2016 19:21:12 +0000 (UTC) |
branch: master
commit e23a053b0041e4f615649b7acf8c1b2ce35fd3fb
Author: Noam Postavsky <address@hidden>
Commit: Noam Postavsky <address@hidden>
Avoid bug in insert-file-contents with REPLACE=t
* yasnippet.el (yas--load-directory-2): Call `erase-buffer' before
`insert-file-contents' instead of passing non-nil REPLACE, avoids Emacs
bug #23659.
Fixes #707.
---
yasnippet.el | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/yasnippet.el b/yasnippet.el
index f670a29..7b87cd3 100644
--- a/yasnippet.el
+++ b/yasnippet.el
@@ -1805,7 +1805,10 @@ With prefix argument USE-JIT do jit-loading of snippets."
(with-temp-buffer
(dolist (file (yas--subdirs directory 'no-subdirs-just-files))
(when (file-readable-p file)
- (insert-file-contents file nil nil nil t)
+ ;; Erase the buffer instead of passing non-nil REPLACE to
+ ;; `insert-file-contents' (avoids Emacs bug #23659).
+ (erase-buffer)
+ (insert-file-contents file)
(push (yas--parse-template file)
snippet-defs))))
(when snippet-defs
- [elpa] master bd30a30 04/36: yas-dont-activate is a hook, (continued)
- [elpa] master bd30a30 04/36: yas-dont-activate is a hook, Noam Postavsky, 2016/06/11
- [elpa] master c1b2cb7 17/36: Improve documentation for new register option, Noam Postavsky, 2016/06/11
- [elpa] master 4c6064c 01/36: Avoid potential problems with user's hooks, Noam Postavsky, 2016/06/11
- [elpa] master 5d44a9f 19/36: Revert "Disable region wrapping for trigger key expansion", Noam Postavsky, 2016/06/11
- [elpa] master beb2ba4 21/36: Fix fields following $0 + region insertion, Noam Postavsky, 2016/06/11
- [elpa] master eeb4b62 14/36: Add new tests for multi-line mirror indentation, Noam Postavsky, 2016/06/11
- [elpa] master 78fe979 22/36: Support htmlize.el in Rakefile doc target, Noam Postavsky, 2016/06/11
- [elpa] master 7f03a23 07/36: Change Emacs installation method for Travis CI, Noam Postavsky, 2016/06/11
- [elpa] master 0d79e69 30/36: Extra measures to prevent premature yas-minor-mode, Noam Postavsky, 2016/06/11
- [elpa] master 497867c 32/36: Rename yas-backport-obsolete-alias, Noam Postavsky, 2016/06/11
- [elpa] master e23a053 34/36: Avoid bug in insert-file-contents with REPLACE=t,
Noam Postavsky <=
- [elpa] master 567ada0 06/36: Decide field clearing based on command's effect, Noam Postavsky, 2016/06/11
- [elpa] master bdfab67 24/36: Make yasnippet less chatty, Noam Postavsky, 2016/06/11
- [elpa] master bbfa1f0 31/36: Add yas-backport-obsolete-alias option, Noam Postavsky, 2016/06/11
- [elpa] master bfe14f1 10/36: Test and fix problem with mirror+autofill, Noam Postavsky, 2016/06/11
- [elpa] master df229b9 23/36: Fix some doc formatting, Noam Postavsky, 2016/06/11
- [elpa] master 1b8f5b7 29/36: Don't use major-mode syntax-propertize-function, Noam Postavsky, 2016/06/11
- [elpa] master 47dbe93 33/36: Fix broken links in README.mdown, Noam Postavsky, 2016/06/11
- [elpa] master dc3e4ca 35/36: Release 0.10.0, Noam Postavsky, 2016/06/11
- [elpa] master ccc9adc 16/36: Add register option for yas-wrap-around-region, Noam Postavsky, 2016/06/11
- [elpa] master eca2f99 15/36: Indent multi-line output from mirrors, Noam Postavsky, 2016/06/11