| OLD | NEW |
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef V8_PARSING_PARSER_BASE_H | 5 #ifndef V8_PARSING_PARSER_BASE_H |
| 6 #define V8_PARSING_PARSER_BASE_H | 6 #define V8_PARSING_PARSER_BASE_H |
| 7 | 7 |
| 8 #include "src/ast/scopes.h" | 8 #include "src/ast/scopes.h" |
| 9 #include "src/bailout-reason.h" | 9 #include "src/bailout-reason.h" |
| 10 #include "src/base/hashmap.h" | 10 #include "src/base/hashmap.h" |
| (...skipping 2455 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2466 } | 2466 } |
| 2467 } | 2467 } |
| 2468 | 2468 |
| 2469 if (delegating) { | 2469 if (delegating) { |
| 2470 return Traits::RewriteYieldStar(generator_object, expression, pos); | 2470 return Traits::RewriteYieldStar(generator_object, expression, pos); |
| 2471 } | 2471 } |
| 2472 | 2472 |
| 2473 expression = Traits::BuildIteratorResult(expression, false); | 2473 expression = Traits::BuildIteratorResult(expression, false); |
| 2474 // Hackily disambiguate o from o.next and o [Symbol.iterator](). | 2474 // Hackily disambiguate o from o.next and o [Symbol.iterator](). |
| 2475 // TODO(verwaest): Come up with a better solution. | 2475 // TODO(verwaest): Come up with a better solution. |
| 2476 typename Traits::Type::YieldExpression yield = | 2476 typename Traits::Type::YieldExpression yield = factory()->NewYield( |
| 2477 factory()->NewYield(generator_object, expression, pos); | 2477 generator_object, expression, pos, Yield::kOnExceptionThrow); |
| 2478 return yield; | 2478 return yield; |
| 2479 } | 2479 } |
| 2480 | 2480 |
| 2481 template <class Traits> | 2481 template <class Traits> |
| 2482 typename ParserBase<Traits>::ExpressionT | 2482 typename ParserBase<Traits>::ExpressionT |
| 2483 ParserBase<Traits>::ParseTailCallExpression(ExpressionClassifier* classifier, | 2483 ParserBase<Traits>::ParseTailCallExpression(ExpressionClassifier* classifier, |
| 2484 bool* ok) { | 2484 bool* ok) { |
| 2485 // TailCallExpression:: | 2485 // TailCallExpression:: |
| 2486 // 'continue' MemberExpression Arguments | 2486 // 'continue' MemberExpression Arguments |
| 2487 // 'continue' CallExpression Arguments | 2487 // 'continue' CallExpression Arguments |
| (...skipping 1163 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3651 has_seen_constructor_ = true; | 3651 has_seen_constructor_ = true; |
| 3652 return; | 3652 return; |
| 3653 } | 3653 } |
| 3654 } | 3654 } |
| 3655 | 3655 |
| 3656 | 3656 |
| 3657 } // namespace internal | 3657 } // namespace internal |
| 3658 } // namespace v8 | 3658 } // namespace v8 |
| 3659 | 3659 |
| 3660 #endif // V8_PARSING_PARSER_BASE_H | 3660 #endif // V8_PARSING_PARSER_BASE_H |
| OLD | NEW |