ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From peter reilly <>
Subject Advice required on committing
Date Wed, 28 May 2003 10:57:25 GMT
Hi, I have just been made a ant committer.

I have found a bug in ant's regular expession
handling for replacing matched groups.

Ant uses \n  to identify the matched group,
jdk14 and jakarta-oro uses $n to identify the
group. The code in ant correctly replaces the \
with $. However, it does not escape any $ on
the input.

The following 
   <replaceregex pattern="@([^@]+)@" replace="${\1}"/>
fails on jdk14 as Matcher#appendReplacement gets passed 
"${$1}" rather than "\${$1}".

My question is:
   should I make a bugzilla entry or just
   commit the changes, with unit test and
   appropriate comment ?


View raw message