ECMAScript Specification: meaning of question mark in the spec

泪湿孤枕 提交于 2019-12-11 02:37:07

问题


I have see many occurrence of Let value be ?, Return ? sth in the specification.example

Anyone know what is the meaning of the ?.


回答1:


From Algorithm Conventions,

Abstract operations referenced using the functional application style and the method application style that are prefixed by ? indicate that ReturnIfAbrupt should be applied to the resulting Completion Record.

For example, ? operationName() is equivalent to ReturnIfAbrupt(operationName()).

Similarly, ? someValue.operationName() is equivalent to ReturnIfAbrupt(someValue.operationName()).



来源:https://stackoverflow.com/questions/41733976/ecmascript-specification-meaning-of-question-mark-in-the-spec

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!