blob: dca7e96d4e86e8f85566dcb1ba8d42f96fd3b8e5 [file] [log] [blame]
Ben Murdoch4a90d5f2016-03-22 12:00:34 +00001// Copyright 2015 the V8 project authors. All rights reserved.
2// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
5// Flags: --allow-natives-syntax
6
7var a = [1.5];
8
9function p() {
10 Array.prototype.push.call(a, 1.7);
11}
12
13p();
14p();
15p();
16%OptimizeFunctionOnNextCall(p);
17p();
18a.push({});
19p();
20assertEquals(1.7, a[a.length - 1]);