v8/test/mjsunit/regress/regress-crbug-548580.js
adamk 06403470e3 Remove --harmony-regexps flag
It's been on since M49. Also moved tests from harmony -> es6,
one of which was merged with another test of the same name.

While moving stuff over to regexp.js, I also noticed that there
were unused calls to %FunctionSetName and %SetNativeFlag (those
calls are already handled by InstallGetter()).

Review URL: https://codereview.chromium.org/1838563003

Cr-Commit-Position: refs/heads/master@{#35076}
2016-03-25 23:02:11 +00:00

16 lines
347 B
JavaScript

// 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.
function store(v) {
var re = /(?=[d#.])/;
re.a = v;
return re;
}
var re1 = store(undefined);
var re2 = store(42);
assertEquals(re1.a, undefined);
assertEquals(re2.a, 42);