зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1155081 - Part 6: Replace ThrowError with ThrowTypeError in Object.js. r=till
This commit is contained in:
Родитель
f0e8daf591
Коммит
836f41fa7e
|
@ -49,7 +49,7 @@ function ObjectDefineSetter(name, setter) {
|
|||
object = ToObject(this);
|
||||
|
||||
if (!IsCallable(setter))
|
||||
ThrowError(JSMSG_BAD_GETTER_OR_SETTER, "setter");
|
||||
ThrowTypeError(JSMSG_BAD_GETTER_OR_SETTER, "setter");
|
||||
|
||||
var key = ToPropertyKey(name);
|
||||
|
||||
|
@ -71,7 +71,7 @@ function ObjectDefineGetter(name, getter) {
|
|||
object = ToObject(this);
|
||||
|
||||
if (!IsCallable(getter))
|
||||
ThrowError(JSMSG_BAD_GETTER_OR_SETTER, "getter");
|
||||
ThrowTypeError(JSMSG_BAD_GETTER_OR_SETTER, "getter");
|
||||
|
||||
var key = ToPropertyKey(name);
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче