| OLD | NEW |
| 1 // Copyright 2011 the V8 project authors. All rights reserved. | 1 // Copyright 2011 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 627 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 638 bool* ok); | 638 bool* ok); |
| 639 | 639 |
| 640 // Strict mode validation of LValue expressions | 640 // Strict mode validation of LValue expressions |
| 641 void CheckStrictModeLValue(Expression* expression, | 641 void CheckStrictModeLValue(Expression* expression, |
| 642 const char* error, | 642 const char* error, |
| 643 bool* ok); | 643 bool* ok); |
| 644 | 644 |
| 645 // Strict mode octal literal validation. | 645 // Strict mode octal literal validation. |
| 646 void CheckOctalLiteral(int beg_pos, int end_pos, bool* ok); | 646 void CheckOctalLiteral(int beg_pos, int end_pos, bool* ok); |
| 647 | 647 |
| 648 // For harmony block scoping mode: Check if the scope has conflicting var/let |
| 649 // declarations from different scopes. It covers for example |
| 650 // |
| 651 // function f() { { { var x; } let x; } } |
| 652 // function g() { { var x; let x; } } |
| 653 // |
| 654 // The var declarations are hoisted to the function scope, but originate from |
| 655 // a scope where the name has also been let bound or the var declaration is |
| 656 // hoisted over such a scope. |
| 657 void CheckConflictingVarDeclarations(Scope* scope, bool* ok); |
| 658 |
| 648 // Parser support | 659 // Parser support |
| 649 VariableProxy* Declare(Handle<String> name, Variable::Mode mode, | 660 VariableProxy* Declare(Handle<String> name, Variable::Mode mode, |
| 650 FunctionLiteral* fun, | 661 FunctionLiteral* fun, |
| 651 bool resolve, | 662 bool resolve, |
| 652 bool* ok); | 663 bool* ok); |
| 653 | 664 |
| 654 bool TargetStackContainsLabel(Handle<String> label); | 665 bool TargetStackContainsLabel(Handle<String> label); |
| 655 BreakableStatement* LookupBreakTarget(Handle<String> label, bool* ok); | 666 BreakableStatement* LookupBreakTarget(Handle<String> label, bool* ok); |
| 656 IterationStatement* LookupContinueTarget(Handle<String> label, bool* ok); | 667 IterationStatement* LookupContinueTarget(Handle<String> label, bool* ok); |
| 657 | 668 |
| (...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 758 private: | 769 private: |
| 759 static const int kTypeSlot = 0; | 770 static const int kTypeSlot = 0; |
| 760 static const int kElementsSlot = 1; | 771 static const int kElementsSlot = 1; |
| 761 | 772 |
| 762 DISALLOW_IMPLICIT_CONSTRUCTORS(CompileTimeValue); | 773 DISALLOW_IMPLICIT_CONSTRUCTORS(CompileTimeValue); |
| 763 }; | 774 }; |
| 764 | 775 |
| 765 } } // namespace v8::internal | 776 } } // namespace v8::internal |
| 766 | 777 |
| 767 #endif // V8_PARSER_H_ | 778 #endif // V8_PARSER_H_ |
| OLD | NEW |