From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Noam Postavsky Newsgroups: gmane.emacs.bugs Subject: bug#31656: 26.1; `fill-paragraph' malformats in emacs-lisp-mode Date: Fri, 01 Jun 2018 21:45:37 -0400 Message-ID: <878t7yarlq.fsf@gmail.com> References: <83sh66g8wb.fsf@gnu.org> <87bmcuc0bo.fsf@gmail.com> <83muwefziz.fsf@gnu.org> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: blaine.gmane.org 1527903856 9654 195.159.176.226 (2 Jun 2018 01:44:16 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sat, 2 Jun 2018 01:44:16 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.1 (gnu/linux) Cc: 31656@debbugs.gnu.org, stefan@automata.se To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sat Jun 02 03:44:12 2018 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 1fOvaR-0002Ka-Dd for geb-bug-gnu-emacs@m.gmane.org; Sat, 02 Jun 2018 03:44:07 +0200 Original-Received: from localhost ([::1]:58051 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fOvcY-0001Nr-Ck for geb-bug-gnu-emacs@m.gmane.org; Fri, 01 Jun 2018 21:46:18 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:50035) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fOvcL-0001Nk-OA for bug-gnu-emacs@gnu.org; Fri, 01 Jun 2018 21:46:06 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fOvcI-0001aM-Mh for bug-gnu-emacs@gnu.org; Fri, 01 Jun 2018 21:46:05 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:50365) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1fOvcI-0001a7-IS for bug-gnu-emacs@gnu.org; Fri, 01 Jun 2018 21:46:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1fOvcI-0000pJ-9K for bug-gnu-emacs@gnu.org; Fri, 01 Jun 2018 21:46:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Noam Postavsky Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 02 Jun 2018 01:46:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 31656 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 31656-submit@debbugs.gnu.org id=B31656.15279039473149 (code B ref 31656); Sat, 02 Jun 2018 01:46:02 +0000 Original-Received: (at 31656) by debbugs.gnu.org; 2 Jun 2018 01:45:47 +0000 Original-Received: from localhost ([127.0.0.1]:58262 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fOvc3-0000oi-N0 for submit@debbugs.gnu.org; Fri, 01 Jun 2018 21:45:47 -0400 Original-Received: from mail-it0-f65.google.com ([209.85.214.65]:40560) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fOvc1-0000oU-Tz for 31656@debbugs.gnu.org; Fri, 01 Jun 2018 21:45:46 -0400 Original-Received: by mail-it0-f65.google.com with SMTP id j186-v6so4029516ita.5 for <31656@debbugs.gnu.org>; Fri, 01 Jun 2018 18:45:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=jz8CmcM00gSdtmEh82o1bU2KJ0Ai/BXUUct2QxvLiXA=; b=fXpTLcikAk/ypWTnAKwIIvz5InDcne26l++Qh5mgY7fG8FStAX+7w+vFmoAbJRY0bH t+sSbssP04+eFLX7DscyvXTbdDgx0nFpglAEhu00nHtwEV7yxUP2S/kgVINwJ9Fb/XMu NBhtBXsVjTEdZj1A/moBKUE61k8dphvpsyLRpaUSeVaLosKDwucbJz/9JT1mBlIq4phj m8BnHoy8NrI+I9Hdtb8wJ9UEUiikDh7Ttk2n3i+zGAeHoGMqXbuyyOWTMJ2sdjN3swvV CLBrNwj5CiqX/oRJQ16i7MmN9271nBY6soUdzIAV3K3f6GxOZOORpGoXByO7z7ryn5tL 47PQ== 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:references:date:in-reply-to :message-id:user-agent:mime-version; bh=jz8CmcM00gSdtmEh82o1bU2KJ0Ai/BXUUct2QxvLiXA=; b=GqI3pJxkM3GEKJR1VARVh9XUUEZ5gpiKSE7YI8zBrVh+NScykKQVcs5dFRC9MkHJb0 WiyPdt3CD4cJjzhMRT6RZ2g4xm6bZSnnD9/Hmm8PLZRPnE5/BLS+zmWmQGchor2f3YkE cZrCthIMLjhP6yN0ahpyAbnkY5e8HJzKxAE8s0CeKApRpr8FBc2c4Vz/BO3EN4M4bfpN F7RzcD2dhQihqDtRB+wJWPjZny4gwr4LYXQ/Q1jeESUeHCu3QZ1WXC6QA5tvtKE0Ihtv oh57ojN+1haM66OGVFuFtOhcFh5dITwvFHpcoX8U1mWrt5In1bU4Qu26yuYL+DNuc5Vg GaXw== X-Gm-Message-State: APt69E2GMY3Uj+DAMdLY0XKi6v2tEG+f/wUftPR0OmNpdVx35yp+jkxk qdr1VhSVVzQFq+WnB+DXNF4= X-Google-Smtp-Source: ADUXVKIFaI05Agu2zMFJUc1XVoMAuKWX0XcRVQxAWSNogBrRiJIJttStBEVajoHeXnPb1RVE1jtyqA== X-Received: by 2002:a24:4516:: with SMTP id y22-v6mr6556292ita.109.1527903940331; Fri, 01 Jun 2018 18:45:40 -0700 (PDT) Original-Received: from zebian (cbl-45-2-119-34.yyz.frontiernetworks.ca. [45.2.119.34]) by smtp.googlemail.com with ESMTPSA id q11-v6sm3183869ita.15.2018.06.01.18.45.38 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Fri, 01 Jun 2018 18:45:39 -0700 (PDT) In-Reply-To: <83muwefziz.fsf@gnu.org> (Eli Zaretskii's message of "Fri, 01 Jun 2018 15:43:16 +0300") 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:146834 Archived-At: Eli Zaretskii writes: > And if you set the value of emacs-lisp-docstring-fill-column to 80, > the value of fill-column that, according to the OP, should have been > used instead, do you get a better-looking nonsense? No, I was thinking more along the aligns of: --- i/lisp/emacs-lisp/lisp-mode.el +++ w/lisp/emacs-lisp/lisp-mode.el @@ -1314,6 +1314,7 @@ lisp-fill-paragraph ;; ;; The `fill-column' is temporarily bound to ;; `emacs-lisp-docstring-fill-column' if that value is an integer. + (when (nth 3 (syntax-ppss)) ; Only fill inside strings. (let ((paragraph-start (concat paragraph-start "\\|\\s-*\\([(;\"]\\|\\s-:\\|`(\\|#'(\\)")) @@ -1323,7 +1324,7 @@ lisp-fill-paragraph (derived-mode-p 'emacs-lisp-mode)) emacs-lisp-docstring-fill-column fill-column))) - (fill-paragraph justify)) + (fill-paragraph justify))) ;; Never return nil. t)) I think this covers the scenario in the OP.