From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: "Basil L. Contovounesios" Newsgroups: gmane.emacs.bugs Subject: bug#30489: 26.0.91; [PATCH] Data associated with json-readtable-error not a list Date: Fri, 16 Feb 2018 17:29:43 +0000 Message-ID: <87sha09720.fsf@tcd.ie> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Trace: blaine.gmane.org 1518802460 4566 195.159.176.226 (16 Feb 2018 17:34:20 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Fri, 16 Feb 2018 17:34:20 +0000 (UTC) To: 30489@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Fri Feb 16 18:34:16 2018 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1emjtb-0008Pv-NF for geb-bug-gnu-emacs@m.gmane.org; Fri, 16 Feb 2018 18:34:03 +0100 Original-Received: from localhost ([::1]:43279 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1emjvc-0007z3-2F for geb-bug-gnu-emacs@m.gmane.org; Fri, 16 Feb 2018 12:36:08 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:43733) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1emjqk-0003pS-9q for bug-gnu-emacs@gnu.org; Fri, 16 Feb 2018 12:31:07 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1emjqg-0000or-RR for bug-gnu-emacs@gnu.org; Fri, 16 Feb 2018 12:31:06 -0500 Original-Received: from debbugs.gnu.org ([208.118.235.43]:39257) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1emjqg-0000oe-Ml for bug-gnu-emacs@gnu.org; Fri, 16 Feb 2018 12:31:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1emjqg-0000n3-Gc for bug-gnu-emacs@gnu.org; Fri, 16 Feb 2018 12:31:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: "Basil L. Contovounesios" Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 16 Feb 2018 17:31:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 30489 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Original-Received: via spool by submit@debbugs.gnu.org id=B.15188022052912 (code B ref -1); Fri, 16 Feb 2018 17:31:02 +0000 Original-Received: (at submit) by debbugs.gnu.org; 16 Feb 2018 17:30:05 +0000 Original-Received: from localhost ([127.0.0.1]:47154 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1emjpl-0000ku-Hp for submit@debbugs.gnu.org; Fri, 16 Feb 2018 12:30:05 -0500 Original-Received: from eggs.gnu.org ([208.118.235.92]:52250) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1emjpj-0000jv-7Q for submit@debbugs.gnu.org; Fri, 16 Feb 2018 12:30:03 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1emjpd-000857-2G for submit@debbugs.gnu.org; Fri, 16 Feb 2018 12:29:57 -0500 Original-Received: from lists.gnu.org ([2001:4830:134:3::11]:54059) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1emjpc-00084x-To for submit@debbugs.gnu.org; Fri, 16 Feb 2018 12:29:56 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:43220) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1emjpb-0002pZ-Pn for bug-gnu-emacs@gnu.org; Fri, 16 Feb 2018 12:29:56 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1emjpY-00082T-Mv for bug-gnu-emacs@gnu.org; Fri, 16 Feb 2018 12:29:55 -0500 Original-Received: from mail-wm0-x229.google.com ([2a00:1450:400c:c09::229]:37448) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1emjpY-00081B-EA for bug-gnu-emacs@gnu.org; Fri, 16 Feb 2018 12:29:52 -0500 Original-Received: by mail-wm0-x229.google.com with SMTP id v71so4436275wmv.2 for ; Fri, 16 Feb 2018 09:29:51 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=tcd-ie.20150623.gappssmtp.com; s=20150623; h=from:to:subject:date:message-id:mime-version; bh=EI9TF2CruaKLkZeRMvA3l1U5WZ8hoydhrrpM0dXiTWw=; b=fuXEPVCIPY2E6ke2k532RnNoUS0dP3JQTJzWeml26BQRNBkDF9REnmOrLiH6gtsysE kySY+lf7C87UCPtK8MeXTU6VOdB+GN+D85CsadCeExgExF+0Z1HslI2eEAh7QU0qvR9f cn13SdcE2EfP+zgoKWA9Or2hH47dr+5USKmTrPqeYESRPJGwpsl9moZkN18ujxkQYr/O E3CaThIz+ZbMgojubF8OnlkA5cSZQ8zh63FKz0xugkkF7FvoBfNPeISpmYC7N67f5yrn hrg4dzzaEyrVRmMtJcGAQTPtI+lflpYe02cGWeAaBFXCJ7FbIrZaZT9Tjb4FzCHGmMzA CZgg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:mime-version; bh=EI9TF2CruaKLkZeRMvA3l1U5WZ8hoydhrrpM0dXiTWw=; b=NEAX3KJ+ZtCqXrSmMxV/UvoBhJIqFAUCAutq6n8BdT8j5OQ4H0PshVhyVsJ2H/+df7 ZEYXSuDPqiWNizxPO/al8KeIPtUlwqw2Th81GEyA8XPMBdxUY4nPPnencBBlOd83Mwas h1Jy/8wO5VnnTMH8F0PSd6FzXHsEFlVd+28/MNE/g3ekqMxR1DydPVOB2OzDbYrfOuBS byA7cZG8FHKE27twTSjMy9IbdcEYeWAUBFt9tH0ukyc0EM3yp1Pt9Ha1lndBmDxzoie7 tyipjM4v63w2QoD904jzjp/xamn5C1SvRpPdRZMSvTW0FmK7cqHCXjU6u6aLXMgmEF73 ZZmA== X-Gm-Message-State: APf1xPAzkvk+iXlmbRzRsxfUMAMwzYYDJjRGcmIbFzJTKLbV2wwiWU0L +wRJywVHKEenAgJoCuKy1vbEWIJT X-Google-Smtp-Source: AH8x2261kZ8/vNQRcjqBwuywInN2zoZTIAuMKE650MFBcYPd6QW9KvoNEirpmsAKLC7sAvlF6kym5g== X-Received: by 10.80.168.227 with SMTP id k90mr8955682edc.249.1518802189995; Fri, 16 Feb 2018 09:29:49 -0800 (PST) Original-Received: from localhost ([213.233.149.9]) by smtp.gmail.com with ESMTPSA id s26sm12643528eds.49.2018.02.16.09.29.48 for (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Fri, 16 Feb 2018 09:29:48 -0800 (PST) X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:143351 Archived-At: --=-=-= Content-Type: text/x-diff Content-Disposition: attachment; filename=0001-lisp-json.el-json-readtable-dispatch-Fix-error-data.patch >From d297d156fec4d141c6287d3da4e7aa538280b43e Mon Sep 17 00:00:00 2001 From: "Basil L. Contovounesios" Date: Fri, 16 Feb 2018 17:11:49 +0000 Subject: [PATCH] * lisp/json.el (json-readtable-dispatch): Fix error data --- lisp/json.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/json.el b/lisp/json.el index b03a482ca6..b3267df6e5 100644 --- a/lisp/json.el +++ b/lisp/json.el @@ -685,7 +685,7 @@ json-readtable-dispatch (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. -- 2.15.1 --=-=-= Content-Type: text/plain When signalling json-readtable-error, the macro json-readtable-dispatch passes the unrecognised character as error data verbatim, rather than as a list. Attached is a patch which fixes this. Thanks, -- Basil In GNU Emacs 26.0.91 (build 3, x86_64-pc-linux-gnu, X toolkit, Xaw3d scroll bars) of 2018-02-16 built on thunk Repository revision: edc06adf96f4aa9d8b707181015acfe61d396edb Windowing system distributor 'The X.Org Foundation', version 11.0.11906000 System Description: Debian GNU/Linux testing (buster) --=-=-=--