From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.ciao.gmane.io!not-for-mail From: Dmitry Gutov Newsgroups: gmane.emacs.bugs Subject: bug#40693: 28.0.50; json-encode-alist changes alist Date: Wed, 29 Apr 2020 18:02:52 +0300 Message-ID: <4305317a-73ee-8d4e-dada-1a45ecacc9d6@yandex.ru> References: <87a738jotd.fsf@tcd.ie> <87mu6utxd1.fsf@tcd.ie> <83r1w6ziql.fsf@gnu.org> <82572c3f-fb24-0b01-06ec-47067d9219ca@yandex.ru> <83blnazdly.fsf@gnu.org> <349d9b1b-4659-907e-c6e1-30cdf052c87f@yandex.ru> <83368mz77f.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Injection-Info: ciao.gmane.io; posting-host="ciao.gmane.io:159.69.161.202"; logging-data="24706"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.7.0 Cc: contovob@tcd.ie, darthandrus@gmail.com, 40693@debbugs.gnu.org To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Wed Apr 29 17:04:13 2020 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jToFw-0006IG-EY for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 29 Apr 2020 17:04:12 +0200 Original-Received: from localhost ([::1]:57276 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jToFv-0006DL-FY for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 29 Apr 2020 11:04:11 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:53666) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jToFn-0006Cf-AA for bug-gnu-emacs@gnu.org; Wed, 29 Apr 2020 11:04:03 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.90_1) (envelope-from ) id 1jToFm-0001hC-NF for bug-gnu-emacs@gnu.org; Wed, 29 Apr 2020 11:04:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:60966) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jToFm-0001h0-Aa for bug-gnu-emacs@gnu.org; Wed, 29 Apr 2020 11:04:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1jToFm-0000IZ-7S for bug-gnu-emacs@gnu.org; Wed, 29 Apr 2020 11:04:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Dmitry Gutov Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 29 Apr 2020 15:04:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 40693 X-GNU-PR-Package: emacs Original-Received: via spool by 40693-submit@debbugs.gnu.org id=B40693.15881725821047 (code B ref 40693); Wed, 29 Apr 2020 15:04:02 +0000 Original-Received: (at 40693) by debbugs.gnu.org; 29 Apr 2020 15:03:02 +0000 Original-Received: from localhost ([127.0.0.1]:44276 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jToEo-0000Ge-3q for submit@debbugs.gnu.org; Wed, 29 Apr 2020 11:03:02 -0400 Original-Received: from mail-wm1-f45.google.com ([209.85.128.45]:55372) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jToEm-0000GE-GS for 40693@debbugs.gnu.org; Wed, 29 Apr 2020 11:03:01 -0400 Original-Received: by mail-wm1-f45.google.com with SMTP id e26so2392941wmk.5 for <40693@debbugs.gnu.org>; Wed, 29 Apr 2020 08:03:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=jJ0xlG/tSYvGitimE65NuyaeyhiHIfZubbynUXir/H8=; b=N62xN9i1or/hids5HZMeCzu8dUNyD4+f8VRb6nNMUU2YLrtLMssuwTANzwfjNssyKn bcQlVi4ovebFFD39kiB25hc9381pe3WHF3bXSUmJQJEnBsLnw3BWdQaWO2VChfIfR/dO O2NFP7bekTU+Xng0BItclbZNflvRyTHwGBoP2XWO3u4YazoQ8smfA3VX9ge2LdtQPawU uRfJ9xYXG3BYOcA2CppTy4HqhkMlGOiiv3/juYa3i7U+6lV7IOmXYPV+h1OsbSc5syKp Zz6epWIw6EJ/G1hcIv+RtR3AQcd14UYcSHpjtFYSGtvccg5pWS3tQsxkZsA8zSKtsS7t iswA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:subject:to:cc:references:from:message-id :date:user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=jJ0xlG/tSYvGitimE65NuyaeyhiHIfZubbynUXir/H8=; b=JhfUloGh/KzBnEkstVqNIi4KuZB4Opoy2byDVuwEswn8cvAOf+gXdv5mPrBrVE561x ePhCkpcgNaibqZpmsK9/Rlze8LD74+RZtDeIlfIVKq0rZS2bCO2BZRNOGIre7GN8YM5V 4agszPGH6BDAW0MnM7bD8sJr5Q3/ne4jXfQyf70EQDJCyxYtBVYvUdzxrUSAC4FIYQxr pqhkplkJxREObfwkrVm32+E3e/S9LgC+AtHn/+EGezAusLdSsVZuQ0lrtLKo8FFTxXgg DelqNtXj4sUYfQO6y4FpFHZzfU6Jeewg8h2nl9/E8ypaMpX/l9lt3Zv1OXVu6SsY6i09 xPlQ== X-Gm-Message-State: AGi0Puap1YZdu1Nm3VxG+S5iwD6Sr8TF52HH2XdXtozsw7qCp+xykUbw ioVR7ZBdE6jozrR9+Govd2M/D7o373c= X-Google-Smtp-Source: APiQypLrDeAk+PE2RGY37WPTCBCEMqn33VWVfaVRP41bxiXIjRinYmMfZZh1METLYKdw0W+OzEre1A== X-Received: by 2002:a1c:c345:: with SMTP id t66mr3958919wmf.189.1588172574236; Wed, 29 Apr 2020 08:02:54 -0700 (PDT) Original-Received: from [192.168.0.2] ([66.205.73.129]) by smtp.googlemail.com with ESMTPSA id p6sm30470727wrt.3.2020.04.29.08.02.52 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 29 Apr 2020 08:02:53 -0700 (PDT) In-Reply-To: <83368mz77f.fsf@gnu.org> Content-Language: en-US X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-Received-From: 209.51.188.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-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:179320 Archived-At: On 29.04.2020 17:40, Eli Zaretskii wrote: >> Cc: contovob@tcd.ie, darthandrus@gmail.com, 40693@debbugs.gnu.org >> From: Dmitry Gutov >> Date: Wed, 29 Apr 2020 17:28:05 +0300 >> >>> How about adding an optional argument instead, by default off, to >>> request this behavior? then callers who care about the original alist >>> could request a non-destructive operation, and others won't suffer any >>> slowdown. >> >> The current behavior is unsafe, that's the problem. Also, >> json-encode-alist is called in a recursive fashion, so it'd have to be a >> global variable instead. > > Sounds like a somewhat hairy issue. Then let's put this on master > first. If this turns out to be a very popular change, and no one > complains, we could later back-port it to some 27.x version. *shrug*, I'm certainly not going to insist, but we could push the "slightly slower" simple patch to emacs-27, and go with Basil's refactor (sounds exciting!) on master.