diff options
author | Mihai Bazon <mihai.bazon@gmail.com> | 2014-01-19 06:14:12 -0800 |
---|---|---|
committer | Mihai Bazon <mihai.bazon@gmail.com> | 2014-01-19 06:14:12 -0800 |
commit | 2d8fc616773e30df955de02d99406f114b87490a (patch) | |
tree | 0c04c540b34283612557fa6103220166f4e3dda9 /lib/output.js | |
parent | 75cdbf19aaf03430d56da2ffe201f7403954d422 (diff) | |
parent | 1e31011874b82723c52589adfda3a451f7a9b0e7 (diff) | |
download | tracifyjs-2d8fc616773e30df955de02d99406f114b87490a.tar.gz tracifyjs-2d8fc616773e30df955de02d99406f114b87490a.zip |
Merge pull request #402 from lautis/bom-regexps
Don't unescape byte order marks in regexps
Diffstat (limited to 'lib/output.js')
-rw-r--r-- | lib/output.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/output.js b/lib/output.js index 896defa3..fce2c1ad 100644 --- a/lib/output.js +++ b/lib/output.js @@ -1126,7 +1126,7 @@ function OutputStream(options) { str = str.split("\\\\").map(function(str){ return str.replace(/\\u[0-9a-fA-F]{4}|\\x[0-9a-fA-F]{2}/g, function(s){ var code = parseInt(s.substr(2), 16); - return code == 0x2f || code == 10 || code == 13 || code == 0x2028 || code == 0x2029 ? s : String.fromCharCode(code); + return code == 0xfeff || code == 0x2f || code == 10 || code == 13 || code == 0x2028 || code == 0x2029 ? s : String.fromCharCode(code); }); }).join("\\\\"); } |