diff options
author | Matheus Marchini <mmarchini@netflix.com> | 2020-03-05 10:49:19 -0800 |
---|---|---|
committer | Matheus Marchini <mmarchini@netflix.com> | 2020-03-18 16:23:22 -0700 |
commit | 2883c855e0105b51e5c8020d21458af109ffe3d4 (patch) | |
tree | 26777aad0a398e9f7755c8b65ac76827fe352a81 /deps/v8/src/builtins/regexp-search.tq | |
parent | 5f0af2af2a67216e00fe07ccda11e889d14abfcd (diff) | |
download | node-new-2883c855e0105b51e5c8020d21458af109ffe3d4.tar.gz |
deps: update V8 to 8.1.307.20
PR-URL: https://github.com/nodejs/node/pull/32116
Reviewed-By: Michaƫl Zasso <targos@protonmail.com>
Reviewed-By: Jiawen Geng <technicalcute@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Diffstat (limited to 'deps/v8/src/builtins/regexp-search.tq')
-rw-r--r-- | deps/v8/src/builtins/regexp-search.tq | 19 |
1 files changed, 11 insertions, 8 deletions
diff --git a/deps/v8/src/builtins/regexp-search.tq b/deps/v8/src/builtins/regexp-search.tq index 3c4e57d734..14fb9f9b03 100644 --- a/deps/v8/src/builtins/regexp-search.tq +++ b/deps/v8/src/builtins/regexp-search.tq @@ -20,7 +20,8 @@ namespace regexp { // Call exec. try { const matchIndices: RegExpMatchInfo = - RegExpPrototypeExecBodyWithoutResultFast(regexp, string) + RegExpPrototypeExecBodyWithoutResultFast( + UnsafeCast<JSRegExp>(regexp), string) otherwise DidNotMatch; // Successful match. @@ -38,13 +39,13 @@ namespace regexp { } } - extern macro RegExpBuiltinsAssembler::BranchIfFastRegExpResult( + extern macro RegExpBuiltinsAssembler::BranchIfRegExpResult( implicit context: Context)(Object): never labels IsUnmodified, IsModified; macro - IsFastRegExpResult(implicit context: Context)(execResult: HeapObject): bool { - BranchIfFastRegExpResult(execResult) otherwise return true, return false; + IsRegExpResult(implicit context: Context)(execResult: HeapObject): bool { + BranchIfRegExpResult(execResult) otherwise return true, return false; } transitioning macro RegExpPrototypeSearchBodySlow(implicit context: Context)( @@ -73,7 +74,7 @@ namespace regexp { } // Return the index of the match. - const fastExecResult = Cast<FastJSRegExpResult>(execResult) + const fastExecResult = Cast<JSRegExpResult>(execResult) otherwise return GetProperty(execResult, 'index'); return fastExecResult.index; } @@ -89,11 +90,13 @@ namespace regexp { // ES#sec-regexp.prototype-@@search // RegExp.prototype [ @@search ] ( string ) transitioning javascript builtin RegExpPrototypeSearch( - js-implicit context: Context, receiver: JSAny)(string: JSAny): JSAny { + js-implicit context: NativeContext, + receiver: JSAny)(string: JSAny): JSAny { ThrowIfNotJSReceiver( - receiver, kIncompatibleMethodReceiver, 'RegExp.prototype.@@search'); + receiver, MessageTemplate::kIncompatibleMethodReceiver, + 'RegExp.prototype.@@search'); const receiver = UnsafeCast<JSReceiver>(receiver); - const string: String = ToString_Inline(context, string); + const string: String = ToString_Inline(string); if (IsFastRegExpPermissive(receiver)) { // TODO(pwong): Could be optimized to remove the overhead of calling the |