Taro Muraoka wrote:
> I wrote a patch to make NFA state dump more pretty.
>
> Before patch:
>
> > (11) NFA_MOPEN(0) (-991) (id=11)
> > (10) NFA_SPLIT (-1024) (id=10)
> > ( 8) NFA_MOPEN(1) (-990) (id=8)
> > ( 7) NFA_SPLIT (-1024) (id=7)
> > ( 1) CHAR(f) (102) (id=1)
> > ( 2) CHAR(o) (111) (id=2)
> > ( 3) CHAR(o) (111) (id=3)
> > ( 9) NFA_MCLOSE(1) (-980) (id=9)
> > (10) NFA_SPLIT (-1024) (id=10)
> > ( 4) CHAR(b) (98) (id=4)
> > ( 5) CHAR(a) (97) (id=5)
> > ( 6) CHAR(r) (114) (id=6)
> > ( 9) NFA_MCLOSE(1) (-980) (id=9)
> > (12) NFA_MCLOSE(0) (-981) (id=12)
> > ( 0) NFA_MATCH (-1023) (id=0)
>
> After patch:
>
> > (11) NFA_MOPEN(0) (-991) (id=11)
> > (10) +-NFA_SPLIT (-1024) (id=10)
> > ( 8) +-NFA_MOPEN(1) (-990) (id=8)
> > ( 7) | +-NFA_SPLIT (-1024) (id=7)
> > ( 1) | +-CHAR(f) (102) (id=1)
> > ( 2) | | +-CHAR(o) (111) (id=2)
> > ( 3) | | +-CHAR(o) (111) (id=3)
> > ( 9) | | +-NFA_MCLOSE(1) (-980) (id=9)
> > (10) | | +-NFA_SPLIT (-1024) (id=10)
> > ( 4) | +-CHAR(b) (98) (id=4)
> > ( 5) | +-CHAR(a) (97) (id=5)
> > ( 6) | +-CHAR(r) (114) (id=6)
> > ( 9) | +-NFA_MCLOSE(1) (-980) (id=9)
> > (12) +-NFA_MCLOSE(0) (-981) (id=12)
> > ( 0) +-NFA_MATCH (-1023) (id=0)
>
> This will be great help to debugging NFA with complex patterns.
Thanks.
The change to move fclose() into nfa_print_state() doesn't work though.
--
Are leaders born or made? And if they're made, can we return them under
warranty?
(Scott Adams - The Dilbert principle)
/// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net \\\
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\ an exciting new programming language -- http://www.Zimbu.org ///
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
--
--
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
---
You received this message because you are subscribed to the Google Groups
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.