emacs-devel
[Top][All Lists]
Advanced

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

Multiple bugs in lisp-mode M-q on paragraphs within #|..|# comments


From: Bob Rogers
Subject: Multiple bugs in lisp-mode M-q on paragraphs within #|..|# comments
Date: Sat, 24 Mar 2007 15:32:37 -0400

   I found three such bugs.  To reproduce:

   1.  Copy the Lisp source below the "----" line into a local file such
as test-lisp-commment-fill.lisp, or anything else that ends in ".lisp".
(Don't follow those instructions, just cut-and-paste!)

   2.  "emacs -Q test-lisp-commment-fill.lisp"

First bug:

   3.  Move point anywhere on the line that says "More testing" and type
M-q.  Observe that nothing happens, when it should join up the next
line.  Typing M-q on the next line DTRT.

Second bug:

   4.  Move to any of the paragraphs in the second #|..| comment (though
only the one numbered 4 needs filling), and type M-q.  You will see a
"Search failed" error; afterwards, *Messages* has:

        fill-comment-paragraph: Search failed: "\\(\\(^\\|[^\\\\
        ]\\)\\(\\\\\\\\\\)*\\)\\(;+\\|#|\\) *"

FWIW, the failing search is on line 942 of lisp/textmodes/fill.el, but
making the obvious attempt to fix it (supplying NOERROR true) doesn't
completely solve the problem.

Third bug:

   5.  Add a ";" comment line at the end of the file; a single ";" on
the last line will do.

   6.  Move point to anywhere in the *second* line of the paragraph
numbered 4, and type M-q.  Not only is this paragraph not filled, but
nearly all of the comment text is duplicated several times!

   I can reproduce all of these quite readily in CVS Emacs updated last
night, but none of them fail in Emacs 21.3 (SuSE GNU/Linux 9.0).

   I am hoping the solution(s) will be obvious to someone more familiar
with this code than I.  If I don't hear anything, I will look into it
further.  (Clues gratefully accepted.  ;-)

   TIA,

                                        -- Bob Rogers
                                           http://rgrjr.dyndns.org/

------------------------------------------------------------------------
;;;; Testing M-q in lisp-mode.

(in-package :common-lisp-user)

#|

   More testing.  Foo bar.
Baz quux.

|#

#||

   1.  Start lisp (via M-x slime).

   2.  Compile and load the mini-compiler (C-c C-k).

   3.  Compile and load this file.

   4.  Invoke (recompile-everything) so that *functions-compiled*
and *functions-called* reflect the runtime.

||#





reply via email to

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