summaryrefslogtreecommitdiff
path: root/deps/v8/test/mjsunit/harmony/regexp-match-indices-no-flag.js
blob: 06cf89ad06bfd2794cf4ec9272a54d9f4600d8b8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
// Copyright 2021 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: --no-harmony-regexp-match-indices

// Redefined hasIndices should not reflect in flags without
// --harmony-regexp-match-indices
{
  let re = /./;
  Object.defineProperty(re, "hasIndices", { get: function() { return true; } });
  assertEquals("", re.flags);
}