From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Alex Newsgroups: gmane.emacs.bugs Subject: bug#24622: 26.0.50; lisp-fill-paragraph broken Date: Thu, 12 Oct 2017 20:23:01 -0600 Message-ID: <877evziy62.fsf@gmail.com> References: <57F536BC.7060306@gmx.at> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Trace: blaine.gmane.org 1507861463 13586 195.159.176.226 (13 Oct 2017 02:24:23 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Fri, 13 Oct 2017 02:24:23 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.0.60 (gnu/linux) Cc: Lars Ingebrigtsen , 24622@debbugs.gnu.org To: martin rudalics Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Fri Oct 13 04:24:16 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 1e2pe1-0002XT-S8 for geb-bug-gnu-emacs@m.gmane.org; Fri, 13 Oct 2017 04:24:14 +0200 Original-Received: from localhost ([::1]:48155 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1e2pe9-00057o-9Q for geb-bug-gnu-emacs@m.gmane.org; Thu, 12 Oct 2017 22:24:21 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:55868) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1e2pdv-00054x-Ny for bug-gnu-emacs@gnu.org; Thu, 12 Oct 2017 22:24:11 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1e2pdq-0008AI-PZ for bug-gnu-emacs@gnu.org; Thu, 12 Oct 2017 22:24:07 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:56099) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1e2pdq-0008A7-Ky for bug-gnu-emacs@gnu.org; Thu, 12 Oct 2017 22:24:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1e2pdq-0004FL-CD for bug-gnu-emacs@gnu.org; Thu, 12 Oct 2017 22:24:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Alex Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 13 Oct 2017 02:24:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 24622 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 24622-submit@debbugs.gnu.org id=B24622.150786140416274 (code B ref 24622); Fri, 13 Oct 2017 02:24:02 +0000 Original-Received: (at 24622) by debbugs.gnu.org; 13 Oct 2017 02:23:24 +0000 Original-Received: from localhost ([127.0.0.1]:36547 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1e2pdA-0004EJ-Ja for submit@debbugs.gnu.org; Thu, 12 Oct 2017 22:23:24 -0400 Original-Received: from mail-it0-f47.google.com ([209.85.214.47]:50601) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1e2pd4-0004Dv-Ll for 24622@debbugs.gnu.org; Thu, 12 Oct 2017 22:23:18 -0400 Original-Received: by mail-it0-f47.google.com with SMTP id 72so9596226itl.5 for <24622@debbugs.gnu.org>; Thu, 12 Oct 2017 19:23:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:in-reply-to:references:user-agent:date :message-id:mime-version; bh=omTZXcRk1x01IZOehq2bfSsbZPrI9YnFUXJ92Ukj8+8=; b=PUMEukEXkuXXcmyY3bArb90jRL/VGYomjIHV23MO7PKvsvg2TNUl3imi7f7V8bSAf2 LeQh/5v1hHo+7N9oUJbVbmVgB8Obc5gEYB+bdNQ2qlPosvgFR5Mgz8kl8G1vwDk7cS/O FDaI+AOgGJ43AMtJkRDBXq6YmEuOuGgRg21X4PorqStA1bKAJR21+4l3qTJDj4ieQ5tE PoesT3BfgjexIUAeVnaAFRsiboPjluikuE2zPXQXYpCR49lgA/tQn96ZNGVRxNm2oSb8 FTLZoquNlpYJ1NjPD95c2T4MHzicRb7ZKUM0PKrtvKZHhuLPljE6BqbIWPDLwGawh44t bc8g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:in-reply-to:references :user-agent:date:message-id:mime-version; bh=omTZXcRk1x01IZOehq2bfSsbZPrI9YnFUXJ92Ukj8+8=; b=fgP0PcIW11zl+qCwmCIVCYqsWwTKroRYChLCTjD/fjWU4BlVCSVdTpWWDzCkPOpH25 Pd21wN6ha24jmeXRVm13ljbQqY8dNRCJHOjNBbjszCBfirfwTlon8D5aJDRpyKvywLR7 f+Boyw4cNw87ST79ffvUzhL1xVYA5/n9XEadGupupb1wyrBW77DSXS+kRDwHItLTI9i8 +U78KShZXYxELRzcsKtjEszTWGatfU5uGaCi0jDCVj/IhKhLWl0LroKz4aXvUjqOA2ms Dn2pBppwaSJ5BpW5t/Zj2DhbyUXQEmVRkCuHZJevHJOj0tx7gNfvvXhXKEqHpECAZYQ7 Pprg== X-Gm-Message-State: AMCzsaWyGmSvKvUicysOu4tfcz2Xb+SulP3oNv01DL1YicIh/JeKsL3z xL7dmL1ef9W3rKxxm+miPFQ= X-Google-Smtp-Source: AOwi7QA/gG11Qv5L0N75Acp4Lgz/C33E3/n+t2ETWuelmK19jdUVk8f7B8XJ02X+RNbFoHj+h2KQRA== X-Received: by 10.36.53.75 with SMTP id k72mr336270ita.8.1507861389107; Thu, 12 Oct 2017 19:23:09 -0700 (PDT) Original-Received: from lylat (S010664777d9cebe3.ss.shawcable.net. [70.64.85.59]) by smtp.gmail.com with ESMTPSA id q94sm4225666ioi.18.2017.10.12.19.23.07 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Thu, 12 Oct 2017 19:23:07 -0700 (PDT) In-Reply-To: <57F536BC.7060306@gmx.at> (martin rudalics's message of "Wed, 05 Oct 2016 19:22:04 +0200") 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:138317 Archived-At: --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable martin rudalics writes: > This commit > > commit 866e3c050fe64fee81f29a335a50a11b2562422e > Author: Lars Ingebrigtsen > Date: Thu Apr 28 12:05:15 2016 +0200 > > Don't consider colons to be paragraphs starting chars in strings > > * lisp/emacs-lisp/lisp-mode.el (lisp-fill-paragraph): Don't > consider colons to start paragraphs in (doc) strings > (bug#7751). > > breaks filling doc-strings of defcustoms. As an example consider the > defcustom of =E2=80=98window-min-height=E2=80=99 in window.el: I've included a diff below that appears to solve both bug#7751 and this one, though I can't guarantee that it doesn't blow something else up. Does anyone have any complaints? In any case, I think this bug should be solved before 26.1 is released. --=-=-= Content-Type: text/x-diff Content-Disposition: inline; filename=paragraph.diff Content-Description: paragraph diff --git a/lisp/emacs-lisp/lisp-mode.el b/lisp/emacs-lisp/lisp-mode.el index fd12635d85..93435e1b4b 100644 --- a/lisp/emacs-lisp/lisp-mode.el +++ b/lisp/emacs-lisp/lisp-mode.el @@ -1267,7 +1267,8 @@ lisp-fill-paragraph ;; case). The `;' and `:' stop the paragraph being filled at following ;; comment lines and at keywords (e.g., in `defcustom'). Left parens are ;; escaped to keep font-locking, filling, & paren matching in the source - ;; file happy. + ;; file happy. The `:' must be preceded by whitespace so that keywords + ;; inside of the docstring don't start new paragraphs (Bug#7751). ;; ;; `paragraph-separate': A clever regexp distinguishes the first line of ;; a docstring and identifies it as a paragraph separator, so that it @@ -1280,13 +1281,7 @@ lisp-fill-paragraph ;; `emacs-lisp-docstring-fill-column' if that value is an integer. (let ((paragraph-start (concat paragraph-start - (format "\\|\\s-*\\([(;%s\"]\\|`(\\|#'(\\)" - ;; If we're inside a string (like the doc - ;; string), don't consider a colon to be - ;; a paragraph-start character. - (if (nth 3 (syntax-ppss)) - "" - ":")))) + "\\|\\s-*\\([(;\"]\\|\\s-:\\|`(\\|#'(\\)")) (paragraph-separate (concat paragraph-separate "\\|\\s-*\".*[,\\.]$")) (fill-column (if (and (integerp emacs-lisp-docstring-fill-column) --=-=-=--