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

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

Re: string-match bug?


From: Peter Dyballa
Subject: Re: string-match bug?
Date: Tue, 8 Dec 2009 12:31:16 +0100


Am 08.12.2009 um 11:50 schrieb Andreas Röhler:

Barry Margolin wrote:
In article <mailman.12469.1260221021.2239.help-gnu-emacs@gnu.org>,
Matthew Dempsky matthew dempsky wrote:

Here's another example of a limit case:

(string-match "a*" "b") returns 0, because a* matches zero or more a's,
and there are zero a's at position 0.


Hmm, interesting

IMHO that differs:

(string-match "a*" "b") asks for a non-occurrence too. So "0" of first position is plausible.


Aren't the regular expressions "" and "a*" equivalent in that respect that they both also match the empty string?

--
Mit friedvollen Grüßen

  Pete

Sending unsolicited commercial eMail to this account incurs a fee of € 500 per message and acknowledges the legality of this contract.





reply via email to

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