From: Aryeh Gregor Date: Sun, 27 Dec 2009 15:44:24 +0000 (+0000) Subject: - in regex character classes has special meaning X-Git-Tag: 1.31.0-rc.0~38466 X-Git-Url: https://git.heureux-cyclage.org/?a=commitdiff_plain;h=11e48bd03b80d57e6e242ad94a707ced00d81aee;p=lhc%2Fweb%2Fwiklou.git - in regex character classes has special meaning Fix for r60376, pointed out by Thana on bug 21946. --- diff --git a/skins/common/wikibits.js b/skins/common/wikibits.js index 95b2e06974..11361df20b 100644 --- a/skins/common/wikibits.js +++ b/skins/common/wikibits.js @@ -705,9 +705,9 @@ function ts_initTransformTable() { // if percents and regular numbers aren't being mixed. ts_number_regex = new RegExp( "^(" + - "[+-\u2212]?[0-9][0-9,]*(\\.[0-9,]*)?(E[+-\u2212]?[0-9][0-9,]*)?" + // Fortran-style scientific + "[-+\u2212]?[0-9][0-9,]*(\\.[0-9,]*)?(E[-+\u2212]?[0-9][0-9,]*)?" + // Fortran-style scientific "|" + - "[+-\u2212]?" + digitClass + "+%?" + // Generic localised + "[-+\u2212]?" + digitClass + "+%?" + // Generic localised ")$", "i" ); }