我創建了一個ASP.net應用程序並安裝了saxon-他使用了塊體包管理器。我想使用n flag來使用標準的.NET正則表達式引擎,從而允許本機.NET正則表達式語法。這僅在.NET平臺上受支持。saxon .net 9.7正則表達式中的語法錯誤:無法識別的標誌'n'
然而,我發現了以下錯誤:
{"Syntax error in regular expression: unrecognized flag 'n'"}
我創建了一個ASP.net應用程序並安裝了saxon-他使用了塊體包管理器。我想使用n flag來使用標準的.NET正則表達式引擎,從而允許本機.NET正則表達式語法。這僅在.NET平臺上受支持。saxon .net 9.7正則表達式中的語法錯誤:無法識別的標誌'n'
然而,我發現了以下錯誤:
{"Syntax error in regular expression: unrecognized flag 'n'"}
:
The code to support the "n" flag is there in the product, though I'm not sure whether it has been recently tested.
Note that the flag must be separated from standard flags by a semicolon, e.g. flags="s;n" or flags=";n".
I think that unlike other Saxon extensions this one is available in HE without a license key.
Note also that you can set the .NET regex engine as your default by setting the configuration parameter " http://saxon.sf.net/feature/defaultRegexEngine " to the value "N".
邁克爾·凱
的分號解決了該問題