| OLD | NEW |
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
| 2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
| 3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
| 4 // met: | 4 // met: |
| 5 // | 5 // |
| 6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
| 7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
| 8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
| 9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
| 10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
| (...skipping 640 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 651 bool Check(i::Token::Value token) { | 651 bool Check(i::Token::Value token) { |
| 652 i::Token::Value next = peek(); | 652 i::Token::Value next = peek(); |
| 653 if (next == token) { | 653 if (next == token) { |
| 654 Consume(next); | 654 Consume(next); |
| 655 return true; | 655 return true; |
| 656 } | 656 } |
| 657 return false; | 657 return false; |
| 658 } | 658 } |
| 659 void ExpectSemicolon(bool* ok); | 659 void ExpectSemicolon(bool* ok); |
| 660 | 660 |
| 661 bool CheckInOrOf(); | 661 bool CheckInOrOf(bool accept_OF); |
| 662 | 662 |
| 663 static int Precedence(i::Token::Value tok, bool accept_IN); | 663 static int Precedence(i::Token::Value tok, bool accept_IN); |
| 664 | 664 |
| 665 void SetStrictModeViolation(i::Scanner::Location, | 665 void SetStrictModeViolation(i::Scanner::Location, |
| 666 const char* type, | 666 const char* type, |
| 667 bool* ok); | 667 bool* ok); |
| 668 | 668 |
| 669 void CheckDelayedStrictModeViolation(int beg_pos, int end_pos, bool* ok); | 669 void CheckDelayedStrictModeViolation(int beg_pos, int end_pos, bool* ok); |
| 670 | 670 |
| 671 void StrictModeIdentifierViolation(i::Scanner::Location, | 671 void StrictModeIdentifierViolation(i::Scanner::Location, |
| (...skipping 10 matching lines...) Expand all Loading... |
| 682 bool stack_overflow_; | 682 bool stack_overflow_; |
| 683 bool allow_lazy_; | 683 bool allow_lazy_; |
| 684 bool allow_natives_syntax_; | 684 bool allow_natives_syntax_; |
| 685 bool allow_generators_; | 685 bool allow_generators_; |
| 686 bool allow_for_of_; | 686 bool allow_for_of_; |
| 687 bool parenthesized_function_; | 687 bool parenthesized_function_; |
| 688 }; | 688 }; |
| 689 } } // v8::preparser | 689 } } // v8::preparser |
| 690 | 690 |
| 691 #endif // V8_PREPARSER_H | 691 #endif // V8_PREPARSER_H |
| OLD | NEW |