ant-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mben...@apache.org
Subject svn commit: r703525 - in /ant/sandbox/antlibs/props/trunk/src: main/org/apache/ant/props/NestedPropertyExpander.java tests/antunit/nested-test.xml
Date Fri, 10 Oct 2008 17:12:35 GMT
Author: mbenson
Date: Fri Oct 10 10:12:35 2008
New Revision: 703525

URL: http://svn.apache.org/viewvc?rev=703525&view=rev
Log:
nested double dollar bug

Modified:
    ant/sandbox/antlibs/props/trunk/src/main/org/apache/ant/props/NestedPropertyExpander.java
    ant/sandbox/antlibs/props/trunk/src/tests/antunit/nested-test.xml

Modified: ant/sandbox/antlibs/props/trunk/src/main/org/apache/ant/props/NestedPropertyExpander.java
URL: http://svn.apache.org/viewvc/ant/sandbox/antlibs/props/trunk/src/main/org/apache/ant/props/NestedPropertyExpander.java?rev=703525&r1=703524&r2=703525&view=diff
==============================================================================
--- ant/sandbox/antlibs/props/trunk/src/main/org/apache/ant/props/NestedPropertyExpander.java
(original)
+++ ant/sandbox/antlibs/props/trunk/src/main/org/apache/ant/props/NestedPropertyExpander.java
Fri Oct 10 10:12:35 2008
@@ -51,6 +51,8 @@
                 if (o != null) {
                     sb.append(o);
                 } else {
+                    // be aware that the parse position may now have changed; update:
+                    c = pos.getIndex();
                     sb.append(value.charAt(c));
                     pos.setIndex(c + 1);
                 }

Modified: ant/sandbox/antlibs/props/trunk/src/tests/antunit/nested-test.xml
URL: http://svn.apache.org/viewvc/ant/sandbox/antlibs/props/trunk/src/tests/antunit/nested-test.xml?rev=703525&r1=703524&r2=703525&view=diff
==============================================================================
--- ant/sandbox/antlibs/props/trunk/src/tests/antunit/nested-test.xml (original)
+++ ant/sandbox/antlibs/props/trunk/src/tests/antunit/nested-test.xml Fri Oct 10 10:12:35
2008
@@ -81,4 +81,14 @@
     </au:assertTrue>
   </target>
 
+  <target name="testNestedDoubleDollar" depends="setUp">
+    <property name="$$" value="$$.value" />
+    <au:assertTrue>
+      <and>
+        <equals arg1="${$$}" arg2="$$.value" />
+        <equals arg1="${$$}" arg2="${$}" />
+      </and>
+    </au:assertTrue>
+  </target>
+
 </project>



Mime
View raw message