Commit 04aa9436 authored by gsathya's avatar gsathya Committed by Commit bot

array-iterator.js: use object_get_prototype_of instead of directly accessing the proto

Instead of directly looking up Uint8Array.__proto__, to get a hold of
the TypedArray prototype, use object_get_prototype_of. This is a
functionally equivalent, but cleaner approach.

Review-Url: https://codereview.chromium.org/1990983002
Cr-Commit-Position: refs/heads/master@{#36340}
parent f6865cb1
......@@ -22,7 +22,7 @@ var IteratorPrototype = utils.ImportNow("IteratorPrototype");
var iteratorSymbol = utils.ImportNow("iterator_symbol");
var MakeTypeError;
var toStringTagSymbol = utils.ImportNow("to_string_tag_symbol");
var GlobalTypedArray = global.Uint8Array.__proto__;
var GlobalTypedArray = %object_get_prototype_of(global.Uint8Array);
utils.Import(function(from) {
MakeTypeError = from.MakeTypeError;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment