Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1146)

Unified Diff: src/js/harmony-sharedarraybuffer.js

Issue 1477073005: Use new.target in favor of %_IsConstructCall intrinsic (1). (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/js/collection.js ('k') | src/js/harmony-simd.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/js/harmony-sharedarraybuffer.js
diff --git a/src/js/harmony-sharedarraybuffer.js b/src/js/harmony-sharedarraybuffer.js
index b4c34151a355a2012b3b1b8b29df4293d0fde09c..37480617b51c7bea70c14e3f3ea1140e0f9cc51b 100644
--- a/src/js/harmony-sharedarraybuffer.js
+++ b/src/js/harmony-sharedarraybuffer.js
@@ -22,7 +22,7 @@ utils.Import(function(from) {
// -------------------------------------------------------------------
function SharedArrayBufferConstructor(length) { // length = 1
- if (%_IsConstructCall()) {
+ if (!IS_UNDEFINED(new.target)) {
var byteLength = ToPositiveInteger(length, kInvalidArrayBufferLength);
%ArrayBufferInitialize(this, byteLength, kShared);
} else {
« no previous file with comments | « src/js/collection.js ('k') | src/js/harmony-simd.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698