diff --git a/common.gypi b/common.gypi index e73d215a982f72..a04c1df94b539f 100644 --- a/common.gypi +++ b/common.gypi @@ -30,7 +30,7 @@ # Reset this number to 0 on major V8 upgrades. # Increment by one for each non-official patch applied to deps/v8. - 'v8_embedder_string': '-node.45', + 'v8_embedder_string': '-node.46', # Enable disassembler for `--print-code` v8 options 'v8_enable_disassembler': 1, diff --git a/deps/v8/tools/profile.js b/deps/v8/tools/profile.js index cddadaaf53121a..74b4b3bf663f66 100644 --- a/deps/v8/tools/profile.js +++ b/deps/v8/tools/profile.js @@ -1002,33 +1002,10 @@ JsonProfile.prototype.addSourcePositions = function( }; }; -function unescapeString(s) { - s = s.split("\\"); - for (var i = 1; i < s.length; i++) { - if (s[i] === "") { - // Double backslash. - s[i] = "\\"; - } else if (i > 0 && s[i].startsWith("x")) { - // Escaped Ascii character. - s[i] = String.fromCharCode(parseInt(s[i].substring(1, 3), 16)) + - s[i].substring(3); - } else if (i > 0 && s[i].startsWith("u")) { - // Escaped unicode character. - s[i] = String.fromCharCode(parseInt(s[i].substring(1, 5), 16)) + - s[i].substring(5); - } else { - if (i > 0 && s[i - 1] !== "\\") { - printErr("Malformed source string"); - } - } - } - return s.join(""); -} - JsonProfile.prototype.addScriptSource = function(script, url, source) { this.scripts_[script] = { - name : unescapeString(url), - source : unescapeString(source) + name : url, + source : source }; };