Fixing JIRA Issue #1651: https://issues.apache.org/jira/browse/XERCESJ-1651. \w should be processed as [#x0000-#x10FFFF]-[\p{P}\p{Z}\p{C}] as per the XML Schema specification.