[cl-ppcre-devel] missing replacement

0 views
Skip to first unread message

Mario Maio

unread,
Apr 14, 2011, 12:51:25 PM4/14/11
to cl-ppcr...@common-lisp.net
If i try this regexp

(cl-ppcre:regex-replace-all " d {1-3}'" "la presa d 'aria" " d'"
:preserve-case t)

I don't get the expected replacement (remove the space before the
apostrophe)

"la presa d'aria"

whereas Regex Coach works as expected.

Thanks.

Mario

_______________________________________________
cl-ppcre-devel site list
cl-ppcr...@common-lisp.net
http://common-lisp.net/mailman/listinfo/cl-ppcre-devel

Hans Hübner

unread,
Apr 14, 2011, 1:07:59 PM4/14/11
to General interest list about cl-ppcre and cl-unicode
On Thu, Apr 14, 2011 at 6:51 PM, Mario Maio <mario...@libero.it> wrote:
> If i try this regexp
>
> (cl-ppcre:regex-replace-all " d {1-3}'" "la presa d 'aria" " d'"
> :preserve-case t)
>
> I don't get the expected replacement (remove the space before the
> apostrophe)

The correct syntax is {1,3}, not {1-3}.

-Hans

Reply all
Reply to author
Forward
0 new messages