From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Dmitry Gutov Newsgroups: gmane.emacs.devel Subject: Re: Bug #25608 and the comment-cache branch Date: Sun, 12 Feb 2017 17:57:24 +0200 Message-ID: <5dac24ba-a73e-b4f4-f595-30f86564b00a@yandex.ru> References: <20170202202418.GA2505@acm> <83lgtouxpf.fsf@gnu.org> <20170202215154.GB2505@acm> <83h94bvhzw.fsf@gnu.org> <20170205220045.GB2294@acm> <83d1es61li.fsf@gnu.org> <20170211232511.GA13712@acm> <20170212120553.GB3087@acm> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit X-Trace: blaine.gmane.org 1486915090 28297 195.159.176.226 (12 Feb 2017 15:58:10 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sun, 12 Feb 2017 15:58:10 +0000 (UTC) User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.0 Cc: emacs-devel@gnu.org To: Alan Mackenzie , Stefan Monnier Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sun Feb 12 16:58:06 2017 Return-path: Envelope-to: ged-emacs-devel@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 1ccwXM-0006wv-C2 for ged-emacs-devel@m.gmane.org; Sun, 12 Feb 2017 16:58:04 +0100 Original-Received: from localhost ([::1]:52503 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ccwXS-0004xg-3s for ged-emacs-devel@m.gmane.org; Sun, 12 Feb 2017 10:58:10 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:49190) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ccwWr-0004xa-F4 for emacs-devel@gnu.org; Sun, 12 Feb 2017 10:57:34 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ccwWo-0005bk-Cz for emacs-devel@gnu.org; Sun, 12 Feb 2017 10:57:33 -0500 Original-Received: from mail-wr0-x243.google.com ([2a00:1450:400c:c0c::243]:36293) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1ccwWo-0005be-71 for emacs-devel@gnu.org; Sun, 12 Feb 2017 10:57:30 -0500 Original-Received: by mail-wr0-x243.google.com with SMTP id k90so20561668wrc.3 for ; Sun, 12 Feb 2017 07:57:28 -0800 (PST) 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=1nHF+86DxGbrYmKOFoyTI1THHEL12vTNXnRWm7xJU+U=; b=CD0+8uHb3IqkaSLrDM7oTJGsunTyOfqJcZFOC4grDie3ihNpx0ONk1XiQj6EZdqJ4K iy+6G4APLPI/jludYqt8yXO5VmFiwRrpuBf5E+JjNPFsgOeHd0dvc461nuza1LDpvhL1 QTmYm3I/hhlFcXOSEJVzq8zad0KEVxfTLF+W8fN2MNn9pHeNJgm3hB7+SMK7/5LFLiP/ pWN3cvtLFYG6/6LsWBBXywyCMf56M62T2FLKES6xljfh71fxcmQ242BVt62ncKJ1TgG6 /3eiEl1qGWQr2dwVbGGqz86byWwI1RYF03rI/QaSqmiogtKob+hhdMhNaZX2Cji3x8ph XyVw== 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=1nHF+86DxGbrYmKOFoyTI1THHEL12vTNXnRWm7xJU+U=; b=ETd4ZCgbtRxPByg9Tx1GMFI7ywpJNJrEmIHzpc7bGJMPQ3jypWSZQEES6rFFt8QTUH 9SYrEXyhNjmYYtjf72iTL1y+aKbUC/cB9AnN1NqA64TdtInwt43ZWaGylImrLM/R9en9 U1gNPItmzMFVnkPZYct9Q2V4p7RyENSxynS3D9Loh5JqqNh2JoZI6XPTInfpphovZxFs XUu+QD54NJMYGmrxZaB2KPljz7dpaNMl3+kpk5XCCDpONS/oNlQ9iZRMraQ5XGbZB8BV sHE4IRaQu1PYvOp4sOKyrdCofuxHJ8bY34vH6k/y6N9u0tEkT9irOYLvXzeVpOkL4ekG lQng== X-Gm-Message-State: AMke39mqAclOqmoIE+aElOjhdHIKiuGNXrLmsREShF0wz0wNTURN3VQIlkYjTRMXn822aA== X-Received: by 10.223.139.213 with SMTP id w21mr16280888wra.108.1486915047631; Sun, 12 Feb 2017 07:57:27 -0800 (PST) Original-Received: from [192.168.1.3] ([185.105.173.41]) by smtp.googlemail.com with ESMTPSA id 91sm7155814wrd.65.2017.02.12.07.57.26 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 12 Feb 2017 07:57:26 -0800 (PST) In-Reply-To: <20170212120553.GB3087@acm> Content-Language: en-US X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2a00:1450:400c:c0c::243 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.org gmane.emacs.devel:212286 Archived-At: On 12.02.2017 14:05, Alan Mackenzie wrote: > That's incoherent. comment-cache was never intended to help those other > uses, though it appears it could do so for most of them. That > particular flaw we're talking about doesn't appear in comment cache, so > there's nothing to fix there. You're changing a low-level primitive to adhere to a non-flexible view of the world that is incompatible with syntax-ppss. > Maybe sometime. In the meantime, the bug with open parens in column > zero in comments should be fixed. If you're willing to give up narrowing support, that bug can be fixed in no time, with the 20-line patch we all know about. > The question of "widening" is not difficult. Narrowing a buffer should > not change the syntax of the characters in it. Doing so leads to > inconsistencies. Yeah, you really want narrowing to be interpreted the way that is more convenient for your usage habits. I want it to be interpreted that's more convenient for the code I've written and ended up maintaining. Resolving this conflict requires some thought. > If I understand correctly, the problem is that multiple-major-mode modes > are trying to use narrowing to get a null syntactic context. They are > trying this because we don't provide anything better. We should provide > something better. I suggested such a something last spring ("islands"). You suggested implementing a big, ambiguously defined feature. We basically have no way to determine whether it would work out. I've spent some time on that discussion helping you narrow down the specs, but my personal takeaway is that it's too complex. Maybe I'm too unimaginative and lazy, though, so please go ahead and work on a prototype if you're confident. In the meantime, however, we need to keep Emacs compatible with multiple-major-mode modes some other way.