xsl-list
[Top] [All Lists]

Re: [xsl] Why does '#' start a comment in regular expressions with 'x' modifier flag? How can I match '#'?

2006-12-21 13:05:30
Michael Kay wrote:
Now I found out that, at least with Saxon (not sure of others), the '#' character is considered a comment delimiter when the 'x' flag (ignore whitespace) is ignored. Furthermore, it does not appear possible to escape the '#' character.

What version of Saxon are you using (and on what platform)? I think there
was a bug in this area in earlier releases but that it works correctly in
Saxon 8.8.

I tested with 8.8 and the problem indeed seems to be resolved. Thanks. We'll update our applications.

However, I do find a new odd behavior with "\" and a space, in conjunction with the 'x' modifier flag. Without the flag, it raises an exception, with the flag, it makes the match fail on any input. I will notify this on the appropriate list.

Cheers,
-- Abel.

--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--