[MKDoc-commit] [Petal] Fix bug where \-escaped semicolons were not recognised (William

bruno at mkdoc.demon.co.uk bruno at mkdoc.demon.co.uk
Thu Mar 24 14:46:17 GMT 2005


Log Message:
-----------
[Petal] Fix bug where \-escaped semicolons were not recognised (William McKee)

Modified Files:
--------------
    Petal:
        Changes
    Petal/lib/Petal/Canonicalizer:
        XML.pm
    Petal/t/data:
        test_attributes2.xml

-------------- next part --------------
Index: Changes
===================================================================
RCS file: /var/spool/cvs/Petal/Changes,v
retrieving revision 1.134
retrieving revision 1.135
diff -LChanges -LChanges -u -r1.134 -r1.135
--- Changes
+++ Changes
@@ -2,6 +2,7 @@
 
 2.17
     - check that   becomes chr(160) not chr(194) (William McKee)
+    - Fix bug where \-escaped semicolons were not recognised (William McKee)
 
 2.16 Fri Mar 18 15:30:00 2005
     - Added Cookbook.pod documentation and associated tests from William McKee
Index: XML.pm
===================================================================
RCS file: /var/spool/cvs/Petal/lib/Petal/Canonicalizer/XML.pm,v
retrieving revision 1.35
retrieving revision 1.36
diff -Llib/Petal/Canonicalizer/XML.pm -Llib/Petal/Canonicalizer/XML.pm -u -r1.35 -r1.36
--- lib/Petal/Canonicalizer/XML.pm
+++ lib/Petal/Canonicalizer/XML.pm
@@ -494,7 +494,7 @@
     my @new = map {
 	$_ = $class->_encode_backslash_semicolon ($_);
 	"<?var name=\"$_\"?>";
-    } split /(\s|\r|\n)*\;(\s|\r|\n)*/ms, $expr;
+    } $class->_split_expression ($expr);
     
     push @Result, @new;
     $NodeStack[$#NodeStack]->{replace} = 'true';
Index: test_attributes2.xml
===================================================================
RCS file: /var/spool/cvs/Petal/t/data/test_attributes2.xml,v
retrieving revision 1.1
retrieving revision 1.2
diff -Lt/data/test_attributes2.xml -Lt/data/test_attributes2.xml -u -r1.1 -r1.2
--- t/data/test_attributes2.xml
+++ t/data/test_attributes2.xml
@@ -7,4 +7,6 @@
              petal:attributes="baz replace; buzz replace; quxx replace"
              petal-meta:attributes
                  ="petal:attributes string:baz ${baz_meta}\; buzz ${buzz_meta}\; quxx ${quxx_meta}" />
+        <bat petal-meta:content="string:Content\;"></bat>
+        <bat petal-meta:replace="string:Replace\;"></bat>
 </foo>


More information about the MKDoc-commit mailing list