From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Michael Heerdegen Newsgroups: gmane.emacs.bugs Subject: bug#5410: Parenthesis Matching Bug!! Date: Thu, 04 Aug 2016 04:55:16 +0200 Message-ID: <871t25fdkb.fsf@web.de> References: <1263817237.2894.15.camel@matrix-laptop> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: blaine.gmane.org 1470279441 6985 195.159.176.226 (4 Aug 2016 02:57:21 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Thu, 4 Aug 2016 02:57:21 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.1 (gnu/linux) Cc: Matrix , 5410@debbugs.gnu.org To: Andrew Hyatt Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Thu Aug 04 04:57:18 2016 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 1bV8qS-0001C3-6a for geb-bug-gnu-emacs@m.gmane.org; Thu, 04 Aug 2016 04:57:16 +0200 Original-Received: from localhost ([::1]:37537 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bV8qO-0003ih-US for geb-bug-gnu-emacs@m.gmane.org; Wed, 03 Aug 2016 22:57:12 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:37115) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bV8pK-00034c-L3 for bug-gnu-emacs@gnu.org; Wed, 03 Aug 2016 22:56:07 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bV8pG-0008KG-HD for bug-gnu-emacs@gnu.org; Wed, 03 Aug 2016 22:56:05 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:57802) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bV8pG-0008KC-DO for bug-gnu-emacs@gnu.org; Wed, 03 Aug 2016 22:56:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1bV8pG-0003ab-6d for bug-gnu-emacs@gnu.org; Wed, 03 Aug 2016 22:56:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Michael Heerdegen Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 04 Aug 2016 02:56:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 5410 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 5410-submit@debbugs.gnu.org id=B5410.147027933213762 (code B ref 5410); Thu, 04 Aug 2016 02:56:02 +0000 Original-Received: (at 5410) by debbugs.gnu.org; 4 Aug 2016 02:55:32 +0000 Original-Received: from localhost ([127.0.0.1]:55099 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1bV8ol-0003Zs-O2 for submit@debbugs.gnu.org; Wed, 03 Aug 2016 22:55:31 -0400 Original-Received: from mout.web.de ([212.227.15.3]:61142) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1bV8oj-0003Zf-8n for 5410@debbugs.gnu.org; Wed, 03 Aug 2016 22:55:29 -0400 Original-Received: from drachen.dragon ([88.67.73.210]) by smtp.web.de (mrweb001) with ESMTPSA (Nemesis) id 0LakkS-1apAAY0GUa-00kQlN; Thu, 04 Aug 2016 04:55:18 +0200 In-Reply-To: (Andrew Hyatt's message of "Wed, 03 Aug 2016 22:18:50 -0400") X-Provags-ID: V03:K0:T0mqx+heZTwbxXb5cmW6HnSaX4Kh9BglW/1NFyJqf0hNr+6QtRm oR6hFch06JG6/hWwiTla4ycfJL2aGeQN6dGytzrSdJ7pQ2EIgztY4CZmbjLGWWEae13k4qF sv2UCIUNb8VMfhzGlShfZIqZC1qxB9t+zeiTQ+TqtTRPaoC1MJ2l6M2UCN5pgvDYioTIQcA wzqMdjb9g7mdE6XH5S75g== X-UI-Out-Filterresults: notjunk:1;V01:K0:zr1Lv6b+/Q8=:pCtE6XRnYtnrn8ZGmvAOaB zhrTDHj03kJYy+vtClJ6ooPJ4yYChjfSNvFSA53p9DaYy1PpNJ/fc0mVgyce4oooEgpq07wVE eRufl9N0R+w8K+SXFKwi9TEQ/KyQ0dKfDmQQrNwLdXwWfoqLCKUBnokI6BR3kcBUNlJ1d/fkb oR2MgnyDgU3n/Ywix3XdZY8eNFnvxT4L1az4o0ZWCEi7qVwMXRJHzSiX4MKX2SmH6vFbqBnet azRFCBUVrcJI0ZIyaM84ta18oZm4HS7+KVA2vtpfoYMN7hoVMIuubq31e6gwR9upTw6UrjKmE IustZeMqVQI3uIPyRpSi0C0uiBbxELywWdS1ZugvBPZN7Yxav/QsAn/Zn18d8lVn0RExEBmEy 3LR2ATRNlhBMhjk9a94JuUgz5XLlKfXY5dAdkTS9km9K76RN+XmGyWACdI0RdbhLtLb3byKOq xPE0OkRm1AefriV3LwziOE8PPREeGSifze8uqPTNgjQkDTdMN5muqODzGtye3NIyQPSbxRbhI 3A/wC3hC//4zwhw+2z659Tz/iVaWx2yeT6p8GjWYXKJAq2mO32+Cu6FNcwUVGdVIsWDNPMUSV 9HL/RWEzibuqQX46kaOWdyqw140CDnuJYOaKN6KC+L1jdeOYne5lL4XQn69cwDLgJ1jgSG7it AHiy/eMCYqXhWVsBzwVKS7rzDDnT/8rCknjrpL3tsCFIWx3ffaxb3KhISMXskLHJ2e2bTauMf J8bd1Zouc33uRixizwaEUsFN+mKE5PqE7I2aiAPwTegL0XsiuJytoJaa2Cno4+fYyPWXZeq0 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:121813 Archived-At: Andrew Hyatt writes: > Your example reproduces for me in Emacs 25. My guess is that emacs > doesn't really assume that comment lines should be treated as a > contiguous text block. Which is sometimes right, sometimes not, in my > experience. We are talking about `show-paren-mode', right? AFAICT this just calls `scan-sexps' and looks if that errors or not, without doing syntactical analysis itself. `parse-sexp-ignore-comments' influences `scan-sexps's behavior in this regard, and setting it to nil does change the behavior in this case for me. I guess we could use this for a solution. > For example, you could have comments that are something > like: > > // This function does three things: > // 1) Reverse the string > // 2) Uuencode the string > // 3) Rot-13 the string > > Which certainly wouldn't make a lot of sense treated contiguously. Well, we would not loose anything in this case: parens are already shown as mismatches now. Michael.