fc826e3735
Add kInternalizedNonEmptySeqString and make kInternalizedString = kEmptyString | kInternalizedNonEmptySeqString. BUG=chromium:731495 Change-Id: I60a6f37242423407ad97188b3f4bd48ae6989ad2 Reviewed-on: https://chromium-review.googlesource.com/528275 Reviewed-by: Jaroslav Sevcik <jarin@chromium.org> Commit-Queue: Ross McIlroy <rmcilroy@chromium.org> Cr-Commit-Position: refs/heads/master@{#45821}
16 lines
372 B
JavaScript
16 lines
372 B
JavaScript
// Copyright 2016 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
|
|
|
|
function foo() {
|
|
global = "";
|
|
global = global + "bar";
|
|
return global;
|
|
};
|
|
|
|
assertEquals(foo(), "bar");
|
|
%OptimizeFunctionOnNextCall(foo);
|
|
assertEquals(foo(), "bar");
|