From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Stefan Monnier via "Bug reports for GNU Emacs, the Swiss army knife of text editors" Newsgroups: gmane.emacs.bugs Subject: bug#49944: parse-partial-sexp fails to signal an error when (> START LIMIT). Date: Tue, 10 Aug 2021 11:44:55 -0400 Message-ID: References: <87r1f36by6.fsf@gnus.org> <87pmum4wnm.fsf@gnus.org> <87a6lpz9vq.fsf@gnus.org> <83mtppflcu.fsf@gnu.org> <87o8a5xscc.fsf@gnus.org> <83k0ktfh1a.fsf@gnu.org> Reply-To: Stefan Monnier Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="7077"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) Cc: acm@muc.de, Lars Ingebrigtsen , 49944@debbugs.gnu.org To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Tue Aug 10 17:46:29 2021 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 1mDTxV-0001ac-Cv for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 10 Aug 2021 17:46:29 +0200 Original-Received: from localhost ([::1]:36972 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mDTxU-0003Xu-06 for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 10 Aug 2021 11:46:28 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:46562) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mDTx4-0003Wl-U3 for bug-gnu-emacs@gnu.org; Tue, 10 Aug 2021 11:46:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:48959) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mDTx4-0004VE-JU for bug-gnu-emacs@gnu.org; Tue, 10 Aug 2021 11:46:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1mDTx4-0000DT-Hk for bug-gnu-emacs@gnu.org; Tue, 10 Aug 2021 11:46:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Stefan Monnier Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 10 Aug 2021 15:46:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 49944 X-GNU-PR-Package: emacs Original-Received: via spool by 49944-submit@debbugs.gnu.org id=B49944.1628610312764 (code B ref 49944); Tue, 10 Aug 2021 15:46:02 +0000 Original-Received: (at 49944) by debbugs.gnu.org; 10 Aug 2021 15:45:12 +0000 Original-Received: from localhost ([127.0.0.1]:60505 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mDTwF-0000CE-Vh for submit@debbugs.gnu.org; Tue, 10 Aug 2021 11:45:12 -0400 Original-Received: from mailscanner.iro.umontreal.ca ([132.204.25.50]:19117) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mDTwE-0000Bs-7Y for 49944@debbugs.gnu.org; Tue, 10 Aug 2021 11:45:10 -0400 Original-Received: from pmg2.iro.umontreal.ca (localhost.localdomain [127.0.0.1]) by pmg2.iro.umontreal.ca (Proxmox) with ESMTP id 7AD23806A5; Tue, 10 Aug 2021 11:45:04 -0400 (EDT) Original-Received: from mail01.iro.umontreal.ca (unknown [172.31.2.1]) by pmg2.iro.umontreal.ca (Proxmox) with ESMTP id D8971807A2; Tue, 10 Aug 2021 11:45:02 -0400 (EDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=iro.umontreal.ca; s=mail; t=1628610302; bh=7zxYP7+OLsUyNXUwpt8WwA1nLp01XckkeNobXFXZKOE=; h=From:To:Cc:Subject:References:Date:In-Reply-To:From; b=lRr5ewF9Z+UyFL+ZWnSAHeZWHhMkjwr2nxHWpVoHFzj1KgemX/8sNtle2/KJHxWYW 6rhuFDraCvQFuKifrauUwWq9is7zyBRhjOKm3jdqgxKe8BSZqCgPW6AU8pmOsluC78 acLLo2IwxuVDOzQ0TzDZwGbLh44zDOs57ZThqcVxsx/WBzMm5hkZ38yqUgdLV9vzJa 0u/huyVhwiFYCzAuVYcv3N4njgcgo4SOj9DasWmR6jXFwHQmWx1PdmQG0numnOaY/x KYAzrTM3YdvtbBBAGDEZw1/xySOxwdjF/Iw3TI8K9agaIv+05Z6+//ZHZZ0gg8ckNm H32rVhBexeBIQ== Original-Received: from alfajor (104-222-120-40.cpe.teksavvy.com [104.222.120.40]) by mail01.iro.umontreal.ca (Postfix) with ESMTPSA id 9FCBC12034A; Tue, 10 Aug 2021 11:45:02 -0400 (EDT) In-Reply-To: <83k0ktfh1a.fsf@gnu.org> (Eli Zaretskii's message of "Tue, 10 Aug 2021 18:36:33 +0300") X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list 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:211516 Archived-At: > The reordering is the side effect of calling validate_region, so we'd > need to expend extra effort NOT to reorder START and END. > > How about just documenting that OLDSTATE should be the state at START, > and that's it? The current use of `validate_region` means that OLDSTATE will be used as the state at "either FROM or TO, whichever is smaller". So I don't understand what it is you're proposing: if we document that OLDSTATE should be the state at FROM, then we need to change the code so that it never swaps FROM and TO. And if we don't want to change the code, then we should document that OLDSTATE will be used as the state at TO when TO is smaller than FROM. Stefan