GNU bug report logs - #7974
lisp-do-defun on defuns with trailing comments

Previous Next

Package: emacs;

Reported by: Ken Olum <kdo <at> cosmos.phy.tufts.edu>

Date: Thu, 3 Feb 2011 16:44:02 UTC

Severity: normal

Tags: easy, fixed

Fixed in version 27.1

Done: Lars Ingebrigtsen <larsi <at> gnus.org>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Lars Ingebrigtsen <larsi <at> gnus.org>
To: Ken Olum <kdo <at> cosmos.phy.tufts.edu>
Cc: 7974 <at> debbugs.gnu.org
Subject: bug#7974: lisp-do-defun on defuns with trailing comments
Date: Thu, 03 Oct 2019 18:08:14 +0200
Ken Olum <kdo <at> cosmos.phy.tufts.edu> writes:

> If you say lisp-compile-defun on a defun which has a comment on the
> line with the final closing parenthesis, then your defun does not get
> compiled, because emacs sends lisp a form with some close parens added
> at the end of the comment, and naturally lisp does not read them.
>
> One cure for this would be to remove the line
>
> (skip-chars-backward " \t\n\r\f") ;  Makes allegro happy
>
> from lisp-do-defun.  Then emacs would keep the new line
> that terminates the comment at the end of the defun and put the
> close parens after that.

But I guess that fix is there for a reason (that Allegro doesn't like
trailing white space), so I've fixed this in Emacs 27 in a different
manner that keeps the trailing comments out of the region altogether.

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




This bug report was last modified 5 years and 291 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.