[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] feature/gnus-select 537ed97 114/218: Pass json-readtable-e
From: |
Andrew G Cohen |
Subject: |
[Emacs-diffs] feature/gnus-select 537ed97 114/218: Pass json-readtable-error data as a list (bug#30489) |
Date: |
Fri, 14 Dec 2018 03:35:12 -0500 (EST) |
branch: feature/gnus-select
commit 537ed97e9cf8daca8967f11c3124c657a874c704
Author: Basil L. Contovounesios <address@hidden>
Commit: Andrew G Cohen <address@hidden>
Pass json-readtable-error data as a list (bug#30489)
* lisp/json.el (json-readtable-dispatch): Fix error data.
* test/lisp/json-tests.el (test-json-read): Check error data is a
list.
---
lisp/json.el | 2 +-
test/lisp/json-tests.el | 3 ++-
2 files changed, 3 insertions(+), 2 deletions(-)
diff --git a/lisp/json.el b/lisp/json.el
index b03a482..d374f45 100644
--- a/lisp/json.el
+++ b/lisp/json.el
@@ -685,7 +685,7 @@ become JSON objects."
(push (list c 'json-read-number) table))
(pcase-dolist (`(,c . ,rest) table)
(push `((eq ,char ,c) (,@rest)) res))
- `(cond ,@res (t (signal 'json-readtable-error ,char)))))
+ `(cond ,@res (t (signal 'json-readtable-error (list ,char))))))
(defun json-read ()
"Parse and return the JSON object following point.
diff --git a/test/lisp/json-tests.el b/test/lisp/json-tests.el
index 47f8047..ea562e8 100644
--- a/test/lisp/json-tests.el
+++ b/test/lisp/json-tests.el
@@ -309,7 +309,8 @@ Point is moved to beginning of the buffer."
(json-tests--with-temp-buffer ""
(should-error (json-read) :type 'json-end-of-file))
(json-tests--with-temp-buffer "xxx"
- (should-error (json-read) :type 'json-readtable-error)))
+ (let ((err (should-error (json-read) :type 'json-readtable-error)))
+ (should (equal (cdr err) '(?x))))))
(ert-deftest test-json-read-from-string ()
(let ((json-string "{ \"a\": 1 }"))
- [Emacs-diffs] feature/gnus-select e16a1e7 028/218: Replace the obsolete process-kill-without-query in documentation, (continued)
- [Emacs-diffs] feature/gnus-select e16a1e7 028/218: Replace the obsolete process-kill-without-query in documentation, Andrew G Cohen, 2018/12/14
- [Emacs-diffs] feature/gnus-select 672b68c 043/218: Let warning about (:foo) be suppressible (Bug#30499), Andrew G Cohen, 2018/12/14
- [Emacs-diffs] feature/gnus-select f3b9db1 038/218: Improve support for desktop restoration in daemon mode, Andrew G Cohen, 2018/12/14
- [Emacs-diffs] feature/gnus-select b8c0e0c 045/218: Fix create_process bug breaking eudc-expand-inline, Andrew G Cohen, 2018/12/14
- [Emacs-diffs] feature/gnus-select 77705ff 046/218: eshell-eval-using-options: Avoid compiler warning differently, Andrew G Cohen, 2018/12/14
- [Emacs-diffs] feature/gnus-select 97e6ea5 033/218: * test/lisp/vc/vc-tests.el (w32-application-type): Fix declaration., Andrew G Cohen, 2018/12/14
- [Emacs-diffs] feature/gnus-select 8ea5938 083/218: Minor copyedits in mule.texi, Andrew G Cohen, 2018/12/14
- [Emacs-diffs] feature/gnus-select dca8b75 087/218: Support variable-unquoting syntax in bat-mode, Andrew G Cohen, 2018/12/14
- [Emacs-diffs] feature/gnus-select 5224b57 106/218: In frameset save pixel values with frame-resize-pixelwise non-nil (Bug#30141), Andrew G Cohen, 2018/12/14
- [Emacs-diffs] feature/gnus-select 23fb252 097/218: Optimize "make check" and "make check-maybe", Andrew G Cohen, 2018/12/14
- [Emacs-diffs] feature/gnus-select 537ed97 114/218: Pass json-readtable-error data as a list (bug#30489),
Andrew G Cohen <=
- [Emacs-diffs] feature/gnus-select a684aeb 109/218: Add URL handler for file-name-directory (Bug#30444), Andrew G Cohen, 2018/12/14
- [Emacs-diffs] feature/gnus-select 73f9e1d 125/218: * doc/emacs/rmail.texi: Fix broken link., Andrew G Cohen, 2018/12/14
- [Emacs-diffs] feature/gnus-select 82efded 096/218: Call enchant-lsmod correctly when Enchant is installed with a suffix, Andrew G Cohen, 2018/12/14
- [Emacs-diffs] feature/gnus-select bda66bd 132/218: Improve port to NetBSD tzalloc, Andrew G Cohen, 2018/12/14
- [Emacs-diffs] feature/gnus-select aa2ebec 141/218: Extend Tramp's UTF8 tests, Andrew G Cohen, 2018/12/14
- [Emacs-diffs] feature/gnus-select b2b31ae 134/218: ; Spelling fix, Andrew G Cohen, 2018/12/14
- [Emacs-diffs] feature/gnus-select 59a41b8 107/218: Optimize tramp-tests.el, Andrew G Cohen, 2018/12/14
- [Emacs-diffs] feature/gnus-select d74261f 158/218: * doc/lispref/windows.texi (Selecting Windows): Fix a typo., Andrew G Cohen, 2018/12/14
- [Emacs-diffs] feature/gnus-select 367ff81 120/218: More proofreading of the Emacs manual, Andrew G Cohen, 2018/12/14
- [Emacs-diffs] feature/gnus-select e2b6627 049/218: Improve and make use of 'image--get-image', Andrew G Cohen, 2018/12/14