2015-02-03 17:47:24 +00:00
|
|
|
// Copyright 2015 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
|
|
|
|
|
2019-06-12 14:00:50 +00:00
|
|
|
a = {
|
|
|
|
y: 1.5
|
|
|
|
};
|
2015-02-03 17:47:24 +00:00
|
|
|
a.y = 1093445778;
|
|
|
|
b = a.y;
|
2019-06-12 14:00:50 +00:00
|
|
|
c = {
|
|
|
|
y: {}
|
|
|
|
};
|
2015-02-03 17:47:24 +00:00
|
|
|
|
|
|
|
function f() {
|
|
|
|
return {y: b};
|
2019-06-12 14:00:50 +00:00
|
|
|
};
|
|
|
|
%PrepareFunctionForOptimization(f);
|
2015-02-03 17:47:24 +00:00
|
|
|
f();
|
|
|
|
f();
|
|
|
|
%OptimizeFunctionOnNextCall(f);
|
|
|
|
assertEquals(f().y, 1093445778);
|