()
| 3095 | } |
| 3096 | |
| 3097 | parseGeneratorMethod(): Node.FunctionExpression { |
| 3098 | const node = this.createNode(); |
| 3099 | |
| 3100 | const isGenerator = true; |
| 3101 | const previousAllowYield = this.context.allowYield; |
| 3102 | |
| 3103 | this.context.allowYield = true; |
| 3104 | const params = this.parseFormalParameters(); |
| 3105 | this.context.allowYield = false; |
| 3106 | const method = this.parsePropertyMethod(params); |
| 3107 | this.context.allowYield = previousAllowYield; |
| 3108 | |
| 3109 | return this.finalize(node, new Node.FunctionExpression(null, params.params, method, isGenerator)); |
| 3110 | } |
| 3111 | |
| 3112 | // https://tc39.github.io/ecma262/#sec-generator-function-definitions |
| 3113 |
no test coverage detected