From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Tom Tromey Newsgroups: gmane.emacs.devel Subject: Re: Smie-auto-fill =?utf-8?Q?doesn=E2=80=99t?= respect comment-auto-fill-only-comments Date: Mon, 29 May 2017 15:20:35 -0600 Message-ID: <87a85vcqcc.fsf@bapiya> References: <87o9vdj0s5.fsf@tromey.com> <87mvavw0h5.fsf@pokyo> <87r2zidut2.fsf@bapiya> <87d1b1e7e3.fsf@bapiya> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: blaine.gmane.org 1496092887 14820 195.159.176.226 (29 May 2017 21:21:27 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Mon, 29 May 2017 21:21:27 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.0.50 (gnu/linux) Cc: emacs-devel@gnu.org To: Stefan Monnier Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon May 29 23:21:21 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 1dFS6K-0003Xh-8h for ged-emacs-devel@m.gmane.org; Mon, 29 May 2017 23:21:20 +0200 Original-Received: from localhost ([::1]:50558 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dFS6P-0002a9-Co for ged-emacs-devel@m.gmane.org; Mon, 29 May 2017 17:21:25 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:60056) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dFS6J-0002a1-H9 for emacs-devel@gnu.org; Mon, 29 May 2017 17:21:20 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dFS6E-0005u7-Ja for emacs-devel@gnu.org; Mon, 29 May 2017 17:21:19 -0400 Original-Received: from gproxy1-pub.mail.unifiedlayer.com ([69.89.25.95]:40136 helo=outbound-ss-1812.hostmonster.com) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1dFS6E-0005rY-5q for emacs-devel@gnu.org; Mon, 29 May 2017 17:21:14 -0400 Original-Received: from cmgw3 (cmgw4 [10.0.90.84]) by gproxy1.mail.unifiedlayer.com (Postfix) with ESMTP id D3189175A9A for ; Mon, 29 May 2017 15:20:47 -0600 (MDT) Original-Received: from box522.bluehost.com ([74.220.219.122]) by cmgw3 with id SMLi1v00Q2f2jeq01MLlJ4; Mon, 29 May 2017 15:20:47 -0600 X-Authority-Analysis: v=2.2 cv=VKStp5HX c=1 sm=1 tr=0 a=GsOEXm/OWkKvwdLVJsfwcA==:117 a=GsOEXm/OWkKvwdLVJsfwcA==:17 a=tJ8p9aeEuA8A:10 a=lvJZ2fZ4qwd85mKVzOsA:9 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=tromey.com; s=default; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date: References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=aZQDCWZAXP5VZpsuNKl0aewUD8W895j+blaWHSsrRrc=; b=BvKoDM0FQeE60b5sIFmeN9L5bi LuZCrm0Wy8jJ+Lb3ikyyvvkWc7nqiHWpJvNgoKOXhDMHrXRknVBgbZSdm68qcH4dRYbrAa1FlsS8K Y+5a8LeZ4ukMlLudz+w/43y//; Original-Received: from 174-29-43-217.hlrn.qwest.net ([174.29.43.217]:53748 helo=bapiya) by box522.bluehost.com with esmtpsa (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.87) (envelope-from ) id 1dFS5i-0000YI-Ee; Mon, 29 May 2017 15:20:42 -0600 In-Reply-To: (Stefan Monnier's message of "Mon, 22 May 2017 15:12:15 -0400") X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - box522.bluehost.com X-AntiAbuse: Original Domain - gnu.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - tromey.com X-BWhitelist: no X-Source-IP: 174.29.43.217 X-Exim-ID: 1dFS5i-0000YI-Ee X-Source: X-Source-Args: X-Source-Dir: X-Source-Sender: 174-29-43-217.hlrn.qwest.net (bapiya) [174.29.43.217]:53748 X-Source-Auth: tom+tromey.com X-Email-Count: 2 X-Source-Cap: ZWx5bnJvYmk7ZWx5bnJvYmk7Ym94NTIyLmJsdWVob3N0LmNvbQ== X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x [fuzzy] X-Received-From: 69.89.25.95 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:215322 Archived-At: > (let (compos comin) > - ;; If we are not inside a comment and we only auto-fill comments, > - ;; don't do anything (unless no comment syntax is defined). > + ;; If we are not inside a comment don't do anything (unless no > + ;; comment syntax is defined). > (unless (and comment-start > - comment-auto-fill-only-comments > (not (called-interactively-p 'interactive)) > (not (save-excursion > (prog1 (setq compos (comment-beginning)) Stefan> I think we want to remove the whole test: this `unless` is there Stefan> specifically in order to do nothing if we're outside of comments and Stefan> comment-auto-fill-only-comments is non-nil. But now the Stefan> "comment-auto-fill-only-comments is non-nil" case is already handled Stefan> outside, so we can just always do the auto-fill as if Stefan> comment-auto-fill-only-comments were nil. I looked at this, but I don't really understand this code, and there were more spots in the function that seemed to be affected by the setq in the snippet above; so consequently I think someone else ought to do this, and for my part I'm dropping the patch. thanks, Tom