bug-gnu-emacs
[Top][All Lists]
Advanced

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

Re: M-x occur bug: ^[^%]+'


From: Andreas Schwab
Subject: Re: M-x occur bug: ^[^%]+'
Date: Mon, 27 Jan 2003 12:04:35 +0100
User-agent: Gnus/5.090013 (Oort Gnus v0.13) Emacs/21.3.50 (ia64-suse-linux)

karl@freefriends.org (Karl Berry) writes:

|> Emacs 21.2, gnu/linux 2.4.18-14 (red hat 8.0).
|> 
|> $ emacs -q --no-site testfile  # contents of testfile below
|> M-x occur RET
|> ^[^%]+' RET
|> 
|> Resulting *Occur* buffer:
|> 
|> 3 lines matching "^[^%]+'" in buffer test/tmp.
|>      38:      \errhelp = \EMsimple
|>      39:      \errmessage{Undefined command `@end \endthing'}%
|>      52:  \errhelp = \EMsimple
|>      53:  \errmessage{This `@end #1' doesn't have a matching `@#1'}%
|>      92:\let\, = \c
|>      93:\let\dotaccent = \.
|>      94:\def\ringaccent#1{{\accent23 #1}}
|>      95:\let\tieaccent = \t
|>      96:\let\ubaraccent = \b
|>      97:\let\udotaccent = \d
|>      98:\let\acuteaccent = \'  % workaround aux file using ' as escape
|> 
|> 
|> The three matches it found are correct (on lines 39, 53, and 98).
|> However, it is also showing a number of lines that do not match.

Note that [^%] includes the newline character, thus you have three matches
each spanning multiple lines.

Andreas.

-- 
Andreas Schwab, SuSE Labs, schwab@suse.de
SuSE Linux AG, Deutschherrnstr. 15-19, D-90429 Nürnberg
Key fingerprint = 58CA 54C7 6D53 942B 1756  01D3 44D5 214B 8276 4ED5
"And now for something completely different."




reply via email to

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