Actions
Bug #3833
closedProblems using fn:replace() with special characters in replacement string
Start date:
2018-07-04
Due date:
% Done:
100%
Estimated time:
Applies to JS Branch:
1.0, Trunk
Fix Committed on JS Branch:
1.0, Trunk
Fixed in JS Release:
SEF Generated with:
Platforms:
Company:
-
Contact person:
-
Additional contact persons:
-
Description
Bug discovered while working on Issue #3790.
Attempted to convert a supplied string to a regex string (e.g. suitable for use in xsl:analyze-string) by escaping characters explicitly:
fn:replace($search, "[\^\.\\\?\*\+\{\}\(\)\|\$\[\]]", "\\$0" )
However this did not work as expected. Apparently there is some problem handling special characters in the replacement string (the 3rd arg of fn:replace) in the Saxon-JS implementation.
Related issues
Please register to edit this issue
Actions
Also available in: Atom PDF Tracking page