[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Bug in allout-hide-current-leaves
From: |
Ken Manheimer |
Subject: |
Re: Bug in allout-hide-current-leaves |
Date: |
Mon, 21 Jan 2008 13:59:41 -0500 |
dang vnc misfire - please use the patch attached to this message,
instead of the last one.
--
ken
http://myriadicity.net
On Jan 21, 2008 1:49 PM, Ken Manheimer <address@hidden> wrote:
> martin, thanks for the details report. i'm attaching a patch and
> ChangeLog - they includes fixes for some other people's changes, as
> well. details below, inline.
>
> On Jan 19, 2008 12:24 PM, martin rudalics <address@hidden> wrote:
> > To reproduce with Emacs -Q: Open src/keyboard.c, do M-x allout-mode, and
> > M-x allout-hide-current-leaves. Gets me:
> >
> > Debugger entered--Lisp error: (wrong-type-argument number-or-marker-p nil)
> > -(nil nil 2)
> > (max 1 (- allout-recent-prefix-end allout-recent-prefix-beginning
> > allout-header-subtraction))
> > (setq allout-recent-prefix-end (or (match-end 1) (match-end 2))
> > allout-recent-prefix-beginning (or (match-beginning 1) (match-beginning 2))
> > allout-recent-depth (max 1 (- allout-recent-prefix-end
> > allout-recent-prefix-beginning
> > allout-header-subtraction)))
> > allout-prefix-data()
> > [...]
> > execute-extended-command(nil)
> > call-interactively(execute-extended-command)
> >
> > Note that `allout-regexp' is
> >
> > "\\(/\\*_[
> > ]*[\\.,\\*\\+--=>()\\[{}&!\\?#%\"address@hidden:;\\^/\\*_]\\)\\|\\(/\\*_\\|/\\*_\\)+
> > ?[^/*_]\\|\f"
> >
> > hence it cannot possibly match _two_ parenthetical subexpressions.
>
> not quite. that's more clear if you look at the expression as a
> concatenation of a few:
>
> (concat "\\(/\\*_[
> ]*[\\.,\\*\\+--=>()\\[{}&!\\?#%\"address@hidden:;\\^/\\*_]\\)"
> "\\|\\(/\\*_\\|/\\*_\\)+ ?[^/*_]"
> "\\|\f")
>
> the actual problem here is that the match on the third alternative,
> the ^L formfeed, is not itself a top-level alternative in the
> expression. i've rectified that, and some related things.
>
> along the way i discovered that some error handling code was mangled,
> both in a misguided blanket alteration of expressions that look like
> error functions (for which `error' condition handlers in
> condition-case statements can be mistaken), and in the subsequent
> attempt to repair it, which left inert nonsensical code in its wake.
>
>
> --
> ken
> http://myriadicity.net
allout-patch.txt
Description: Text document
ChangeLog-entry.txt
Description: Text document