Index: src/regexp.js |
diff --git a/src/regexp.js b/src/regexp.js |
index 9db8e995b057c5d7c7d992bde3f409d6be04339d..a344b31f8a6c26e5f8db48d1bdf3f3d0e98bc25a 100644 |
--- a/src/regexp.js |
+++ b/src/regexp.js |
@@ -88,8 +88,8 @@ |
// behavior. |
if (this == GlobalRegExp.prototype) { |
// We don't allow recompiling RegExp.prototype. |
- throw MakeTypeError(kIncompatibleMethodReceiver, |
- 'RegExp.prototype.compile', this); |
+ throw MakeTypeError('incompatible_method_receiver', |
+ ['RegExp.prototype.compile', this]); |
} |
if (IS_UNDEFINED(pattern) && %_ArgumentsLength() != 0) { |
DoConstructRegExp(this, 'undefined', flags); |
@@ -146,8 +146,8 @@ |
function RegExpExecJS(string) { |
if (!IS_REGEXP(this)) { |
- throw MakeTypeError(kIncompatibleMethodReceiver, |
- 'RegExp.prototype.exec', this); |
+ throw MakeTypeError('incompatible_method_receiver', |
+ ['RegExp.prototype.exec', this]); |
} |
string = TO_STRING_INLINE(string); |
@@ -194,8 +194,8 @@ |
// else implements. |
function RegExpTest(string) { |
if (!IS_REGEXP(this)) { |
- throw MakeTypeError(kIncompatibleMethodReceiver, |
- 'RegExp.prototype.test', this); |
+ throw MakeTypeError('incompatible_method_receiver', |
+ ['RegExp.prototype.test', this]); |
} |
string = TO_STRING_INLINE(string); |
@@ -256,8 +256,8 @@ |
function RegExpToString() { |
if (!IS_REGEXP(this)) { |
- throw MakeTypeError(kIncompatibleMethodReceiver, |
- 'RegExp.prototype.toString', this); |
+ throw MakeTypeError('incompatible_method_receiver', |
+ ['RegExp.prototype.toString', this]); |
} |
var result = '/' + this.source + '/'; |
if (this.global) result += 'g'; |