bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#31656: 26.1; `fill-paragraph' malformats in emacs-lisp-mode


From: Lars Ingebrigtsen
Subject: bug#31656: 26.1; `fill-paragraph' malformats in emacs-lisp-mode
Date: Sat, 22 Aug 2020 17:23:42 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux)

Noam Postavsky <npostavs@gmail.com> writes:

> Eli Zaretskii <eliz@gnu.org> writes:
>
>> Are there no use cases where we would want M-q outside of syntactic
>> strings?
>
> Okay, I can think of one possibility: if you've pasted a long single
> line consisting of a quoted list of symbols, then M-q could be a
> convenient way of breaking it up into multiple lines.  With M-q disabled
> in Lisp code, you would need to copy the data to a temp non-lisp-mode
> buffer in order to do that, so a bit more inconvenient.

I do use `M-q' on long lists of symbols sometimes (mostly because `pp'
is so unhelpful when rendering those), so it would be annoying to see
that go.

What about just a new, simple filling method for Lisp-like text?  For
instance, if you `M-q' outside of text, it's just convert this:

(defun feedmail-default-date-generator (maybe-file)
  "Default function for generating Date: header contents."
  (feedmail-say-debug ">in-> feedmail-default-date-generator")
  (when maybe-file
    (feedmail-say-debug (concat "4 cre " (feedmail-rfc822-date (nth 4 
(file-attributes maybe-file)))))
    (feedmail-say-debug (concat "5 mod " (feedmail-rfc822-date (nth 5 (file-attr

into this:

(defun feedmail-default-date-generator (maybe-file)
  "Default function for generating Date: header contents."
  (feedmail-say-debug ">in-> feedmail-default-date-generator")
  (when maybe-file
    (feedmail-say-debug (concat "4 cre " (feedmail-rfc822-date (nth 4
(file-attributes maybe-file)))))
    (feedmail-say-debug (concat "5 mod " (feedmail-rfc822-date (nth 5
(file-attr

It'd still be wrong, but at least it wouldn't destroy the strings...

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no





reply via email to

[Prev in Thread] Current Thread [Next in Thread]