We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Error(…)
new Error(…)
extends
super
{ [[Value]]: msg, [[Writable]]: true, [[Enumerable]]: false, [[Configurable]]: true }
初始值为 %Error.prototype%
属性描述符为 { [[Writable]]: false, [[Enumerable]]: false, [[Configurable]]: false }
{ [[Writable]]: false, [[Enumerable]]: false, [[Configurable]]: false }
初始值为 %Error%
初始值为空字符串
初始值为 "Error"
继承自Error原型对象的普通对象,具有 [[ErrorData]] 内置插槽其值为 undefined。[[ErrorData]] 的唯一用途是将Error和 NativeError 实例标识为Object.prototype.toString中的Error对象。
看原规范吧
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Error 对象
Error 构造器
Error(…)
和new Error(…)
效果相同extends
子句的值。打算继承指定的 Error 行为的子类构造函数必须包括对 Error 构造函数的super
调用,以创建和初始化具有内置插槽 [[ErrorData]] 的子类实例。Error ( message )
{ [[Value]]: msg, [[Writable]]: true, [[Enumerable]]: false, [[Configurable]]: true }
Error 构造器属性
Error.prototype
初始值为 %Error.prototype%
属性描述符为
{ [[Writable]]: false, [[Enumerable]]: false, [[Configurable]]: false }
Error 原型对象属性
Error.prototype.constructor
初始值为 %Error%
Error.prototype.message
初始值为空字符串
Error.prototype.name
初始值为 "Error"
Error.prototype.toString ( )
Error 实例对象属性
继承自Error原型对象的普通对象,具有 [[ErrorData]] 内置插槽其值为 undefined。[[ErrorData]] 的唯一用途是将Error和 NativeError 实例标识为Object.prototype.toString中的Error对象。
本标准中使用的错误类型
NativeError 对象结构
看原规范吧
The text was updated successfully, but these errors were encountered: