| Index: src/js/harmony-regexp.js
|
| diff --git a/src/js/harmony-regexp.js b/src/js/harmony-regexp.js
|
| index 033ee2c9a513abecf05a9dbc4b67571fb3a3d516..0aed90c9f4e9a630199ae0b39443e8d943dc9642 100644
|
| --- a/src/js/harmony-regexp.js
|
| +++ b/src/js/harmony-regexp.js
|
| @@ -11,6 +11,7 @@
|
| // -------------------------------------------------------------------
|
| // Imports
|
|
|
| +var GetRegExpFlagGetter = utils.ImportNow("GetRegExpFlagGetter");
|
| var GlobalRegExp = global.RegExp;
|
| var MakeTypeError;
|
|
|
| @@ -24,7 +25,8 @@ utils.Import(function(from) {
|
| // + https://bugs.ecmascript.org/show_bug.cgi?id=3423
|
| function RegExpGetFlags() {
|
| if (!IS_SPEC_OBJECT(this)) {
|
| - throw MakeTypeError(kFlagsGetterNonObject, TO_STRING(this));
|
| + throw MakeTypeError(
|
| + kRegExpNonObject, "RegExp.prototype.flags", TO_STRING(this));
|
| }
|
| var result = '';
|
| if (this.global) result += 'g';
|
| @@ -39,4 +41,9 @@ function RegExpGetFlags() {
|
| RegExpGetFlags, null, DONT_ENUM);
|
| %SetNativeFlag(RegExpGetFlags);
|
|
|
| +%DefineGetterPropertyUnchecked(GlobalRegExp.prototype, "sticky",
|
| + GetRegExpFlagGetter("RegExp.prototype.sticky", 8), DONT_ENUM);
|
| +
|
| +%DefineGetterPropertyUnchecked(GlobalRegExp.prototype, "unicode",
|
| + GetRegExpFlagGetter("RegExp.prototype.unicode", 16), DONT_ENUM);
|
| })
|
|
|