--- Nikola Janceski <[EMAIL PROTECTED]> wrote:
> actually searching on a empty pattern is wrong wrong
> wrong! A pattern in a search that evalutes to "" will
> use the previous successful pattern match.
Lets see what I actually said:
| Split on a null length string is probably more
| readable, but this simple technique works for pairs
| of characters... and allows you to avoid pack() and
| unpack() a little longer!
Did I say empty pattern? No... so you can't assign me
those wrongs. Besides, this works fine:
local $_ = "Hi There";
if (/Hi/) {
print join "-", (split //);
}
which is the opposite of what you implied. The reason
is that for // the default regex is the previous
expression... but for split the default is a single
space character. Split behaves differently from a
normal regex function.
[See page 795 of 3rd Ed. Programming Perl]
Jonathan Paton
__________________________________________________
Do You Yahoo!?
Everything you'll ever need on one web page
from News and Sport to Email and Music Charts
http://uk.my.yahoo.com
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]