nodejs/deps/v8/test/mjsunit/regress/regress-347909.js

21 lines
390 B
JavaScript
Raw Permalink Normal View History

2014-03-13 20:45:44 +04:00
// Copyright 2014 the V8 project authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
// Flags: --allow-natives-syntax
var a = {y: 1.5};
2014-03-18 00:33:01 +04:00
a.y = 0;
var b = a.y;
a.y = {};
var d = 1;
2014-03-13 20:45:44 +04:00
function f() {
2014-03-18 00:33:01 +04:00
d = 0;
return {y: b};
};
%PrepareFunctionForOptimization(f);
2014-03-13 20:45:44 +04:00
f();
f();
%OptimizeFunctionOnNextCall(f);
2014-03-18 00:33:01 +04:00
f();