[cl-ppcre-devel] CL-PPCRE Split behaviour
Sébastien Saint-Sevin
seb-cl-mailist at matchix.com
Mon Aug 27 17:55:52 UTC 2007
Matthew Sachs a écrit :
> Sébastien Saint-Sevin wrote:
>>> I don't know the Perl behaviour in this particular case, but I hope
>>> it is not a peculiar behaviour as the doc says :-)
>>>
>>> Ex : (cl-ppcre:split "\\s+" " foo bar baz ")
>>> ==> ("" "foo" "bar" "baz")
>>>
>>> I would prefer to get ("foo" "bar" "baz")
>
> bash$ perl -e 'print join(" ", map { "\"$_\"" } split(/\s+/, " foo bar
> baz ")), "\n"'
> "" "foo" "bar" "baz"
>
> CL-PPCRE is matching Perl's behavior here.
I'm not that much surprised that PERL can be doing it this way...
Thanks for the perl test, Matthew.
Cheers, Sebastien.
> _______________________________________________
> cl-ppcre-devel site list
> cl-ppcre-devel at common-lisp.net
> http://common-lisp.net/mailman/listinfo/cl-ppcre-devel
>
More information about the Cl-ppcre-devel
mailing list