[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#44858: [PATCH] Make byte-compiler warn about wide docstrings
From: |
Lars Ingebrigtsen |
Subject: |
bug#44858: [PATCH] Make byte-compiler warn about wide docstrings |
Date: |
Thu, 26 Nov 2020 11:49:55 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) |
Stefan Kangas <stefan@marxist.se> writes:
> ** Make byte-compiler warn when a doc string is too wide
>
> Please find attached a patch that implements this.
I like it.
> Notably, it omits defuns, and ignores any lines containing
> `substitute-command-keys' style substitutions.
>
> I've been messing around with getting defuns to work, but I can't find a
> way for it to work reliably. The problem is that they are already macro
> expanded when we start issuing warnings, so it's not trivial to reliably
> separate defuns from other cases where lambda is used.
I'm probably misunderstanding you completely, but do we have to separate
between lambda and defuns? lambdas can also have doc strings...
> (If you were to add defuns into the mix, we would get around 700
> warnings for wide docstrings, several of which would be autogenerated.
> We should probably look into that at some point...)
Yes, the autogenerated docstrings should be fixed, too -- mostly by
running them through `fill-paragraph'.
--
(domestic pets only, the antidote for overdose, milk.)
bloggy blog: http://lars.ingebrigtsen.no