From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Stephen Berman Newsgroups: gmane.emacs.bugs Subject: bug#28003: 26.0.50; Auto fill broken in Message mode Date: Mon, 07 Aug 2017 21:56:42 +0200 Message-ID: <87shh3cft1.fsf@rosalinde> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: blaine.gmane.org 1502135919 24266 195.159.176.226 (7 Aug 2017 19:58:39 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Mon, 7 Aug 2017 19:58:39 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.0.50 (gnu/linux) To: 28003@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Mon Aug 07 21:58:25 2017 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 1deoAG-0005I5-6p for geb-bug-gnu-emacs@m.gmane.org; Mon, 07 Aug 2017 21:58:12 +0200 Original-Received: from localhost ([::1]:39268 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1deoAM-0007YI-GN for geb-bug-gnu-emacs@m.gmane.org; Mon, 07 Aug 2017 15:58:18 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:59569) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1deoAC-0007X2-7E for bug-gnu-emacs@gnu.org; Mon, 07 Aug 2017 15:58:13 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1deoA7-000103-A4 for bug-gnu-emacs@gnu.org; Mon, 07 Aug 2017 15:58:08 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:42065) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1deoA7-0000zk-64 for bug-gnu-emacs@gnu.org; Mon, 07 Aug 2017 15:58:03 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1deoA6-0005Gi-Kq for bug-gnu-emacs@gnu.org; Mon, 07 Aug 2017 15:58:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Stephen Berman Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 07 Aug 2017 19:58:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 28003 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Original-Received: via spool by submit@debbugs.gnu.org id=B.150213582920188 (code B ref -1); Mon, 07 Aug 2017 19:58:02 +0000 Original-Received: (at submit) by debbugs.gnu.org; 7 Aug 2017 19:57:09 +0000 Original-Received: from localhost ([127.0.0.1]:50746 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1deo9F-0005FX-7j for submit@debbugs.gnu.org; Mon, 07 Aug 2017 15:57:09 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:39441) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1deo9E-0005FM-2p for submit@debbugs.gnu.org; Mon, 07 Aug 2017 15:57:08 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1deo93-0000OA-Q8 for submit@debbugs.gnu.org; Mon, 07 Aug 2017 15:57:03 -0400 Original-Received: from lists.gnu.org ([2001:4830:134:3::11]:37709) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1deo93-0000Ny-Na for submit@debbugs.gnu.org; Mon, 07 Aug 2017 15:56:57 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:58476) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1deo8y-0007Kd-Fx for bug-gnu-emacs@gnu.org; Mon, 07 Aug 2017 15:56:57 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1deo8t-0000Ik-7p for bug-gnu-emacs@gnu.org; Mon, 07 Aug 2017 15:56:52 -0400 Original-Received: from mout.gmx.net ([212.227.17.21]:64757) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1deo8s-0000HG-Ra for bug-gnu-emacs@gnu.org; Mon, 07 Aug 2017 15:56:47 -0400 Original-Received: from rosalinde ([83.135.5.181]) by mail.gmx.com (mrgmx102 [212.227.17.168]) with ESMTPSA (Nemesis) id 0LlpJU-1d5TK71erI-00ZQOv for ; Mon, 07 Aug 2017 21:56:43 +0200 X-Provags-ID: V03:K0:FFFmLhI2JCcEeZj6ShC8gPbLXQNUOrDBWvciJQFU3Ay1vzJFzKB dh+Y6Ry5CqDcje1FwdA5ES6aC6GEXiY+VEO8vXiuC6e6LvWQtLjpPIqiUI5K8Uo3lUs9yo2 Xqny9/DL7Jj6nHT5CADromRGb93SwtUyQMniHfS4bRTYGw+Rm3m0PuTu53gWgewY6TZBHxU JX3c6lO3RIMLLR/nb3x2A== X-UI-Out-Filterresults: notjunk:1;V01:K0:uHwIUBwZZUM=:uWAlEVSZeC3IbyO9murt6f 00j9HpgQgZKKK6ADNxYprmSZRGukMeGWTTUmbNXcBc2tkdE08UbYLSvQ8R9qPOYiEUYH7TfZh iu8jlDOsl9h4seRuyJy7yW9JPiADRF8aE0YP8h7I46+K+//VZhsBxrkJqqARN9l4fbFVo935g gbf48DyPmx7xXUKfcCmSYRwGDQclr5O7v1ajZ6MzQzmSfTwl5hqPdIXr9iQVtvFIGTKVuee5G cU9oRiCxJGcmnJ9XkPHrTeTiDY/nhNwS1NoDIXcqa3CtjRWkAdiy5Vag2XZ8yww2O06C2eYQI TmibMfNG9JjNzTRZ4CpsoA4NN+nbuC8Ug1A08hsxZcHnDqOuWek/h1yCb8IKNYv22LDQtmpD8 zW4YMc0LwD4hyjofkXOfO+kT4AtgCGH3Nhhufbdd8FofB1g+v2JH14FHxoEPCIa5rdXDREoc7 CIhWqfB5VD3UIYKydVR431FkWEXI23NMajomJctPYhY1+afti9Cr+tfqvRXUaGYAnz9/gqqOU 5xvOjZ/j8PKSSIwsiB49h5evhCZ/5P/zyrSlRnm6dgiONT8EDAIw1gtqYdEVJjsfN4oV+Lg6d sXqnrjx07UT7V5NKVBU9dcLD5O6lo5qY9530kj+ZzZIptbYxniMXJeETFylTXQObd53msu7Ni LnyFyPWo1/hDzZ5pyake2A8OSiQieh+DsV2MTkExE5WDd5V0pAoftDCGYyxbuFnpTsy0mfv59 oCTPq+7+guuFRKsavW7okOwkQQyb/hr3sl2PLatFdKt+rYnzfG8s0XQ/WEO6VIzCwbM5+UEA X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x 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:135548 Archived-At: This change: commit 9b463fa8648b7baed95a44f4317cb7402fd8bf1c Author: Tom Tromey Date: Sat Aug 5 18:30:52 2017 -0600 Respect comment-auto-fill-only-comments Respect comment-auto-fill-only-comments when auto-filling and a comment syntax is defined. * lisp/newcomment.el (comment-indent-new-line): Do not check comment-auto-fill-only-comments. * lisp/simple.el (internal-auto-fill): New defun. * src/cmds.c (internal_self_insert): Call Qinternal_auto_fill, not auto_fill_function. (syms_of_cmds): Define Qinternal_auto_fill. broke auto filling in Message mode; the breakage is due specifically to this change in comment-indent-new-line: diff --git a/lisp/newcomment.el b/lisp/newcomment.el index 8772b52376..e3ee4dfab1 100644 --- a/lisp/newcomment.el +++ b/lisp/newcomment.el @@ -1382,10 +1382,9 @@ comment-indent-new-line (interactive) (comment-normalize-vars t) (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)) To reproduce: 0. emacs -Q 1. Type `C-x m' to get a Message mode buffer, with a fill-column of 70. 2. Insert at point-max this text (all in one unbroken line): This is a test. This is a test. This is a test. This is a test. This is a test. 3. Point is now in column 79; type SPC. => The line is not broken and filled. 4. Delete the last SPC, type `C-a > SPC C-e SPC'. => This line is now broken and filled. Message mode sets "> " and comment-auto-fill-only-comments to nil by default, but since the above change eliminated checking the latter, after step 3 the unless condition evaluates to t, so there's no auto-filling; while after step 4, (comment-beginning) is non-nil, so the unless condition is nil and auto-filling occurs. In GNU Emacs 26.0.50 (build 2, x86_64-pc-linux-gnu, GTK+ Version 3.22.8) of 2017-08-07 built on rosalinde Repository revision: 14ea76af5f3596d48747c2437006f6e1abcb67a7 Windowing system distributor 'The X.Org Foundation', version 11.0.11901000