Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(206)

Side by Side Diff: src/parser.h

Issue 6144005: Early draft of strict mode (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 9 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « src/messages.js ('k') | src/parser.cc » ('j') | src/parser.cc » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2010 the V8 project authors. All rights reserved. 1 // Copyright 2010 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 664 matching lines...) Expand 10 before | Expand all | Expand 10 after
675 TemporaryScope* temp_scope_; 675 TemporaryScope* temp_scope_;
676 Mode mode_; 676 Mode mode_;
677 677
678 Target* target_stack_; // for break, continue statements 678 Target* target_stack_; // for break, continue statements
679 bool allow_natives_syntax_; 679 bool allow_natives_syntax_;
680 v8::Extension* extension_; 680 v8::Extension* extension_;
681 bool is_pre_parsing_; 681 bool is_pre_parsing_;
682 ScriptDataImpl* pre_data_; 682 ScriptDataImpl* pre_data_;
683 FuncNameInferrer* fni_; 683 FuncNameInferrer* fni_;
684 bool stack_overflow_; 684 bool stack_overflow_;
685 bool strict_mode_; // parsing strict mode code
Lasse Reichstein 2011/01/13 07:18:40 You could (and IMO should) put this bit in the Tem
Martin Maly 2011/01/14 00:06:28 Done.
685 }; 686 };
686 687
687 688
688 // Support for handling complex values (array and object literals) that 689 // Support for handling complex values (array and object literals) that
689 // can be fully handled at compile time. 690 // can be fully handled at compile time.
690 class CompileTimeValue: public AllStatic { 691 class CompileTimeValue: public AllStatic {
691 public: 692 public:
692 enum Type { 693 enum Type {
693 OBJECT_LITERAL_FAST_ELEMENTS, 694 OBJECT_LITERAL_FAST_ELEMENTS,
694 OBJECT_LITERAL_SLOW_ELEMENTS, 695 OBJECT_LITERAL_SLOW_ELEMENTS,
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after
766 Handle<Object> ReportUnexpectedToken() { return Handle<Object>::null(); } 767 Handle<Object> ReportUnexpectedToken() { return Handle<Object>::null(); }
767 // Converts the currently parsed literal to a JavaScript String. 768 // Converts the currently parsed literal to a JavaScript String.
768 Handle<String> GetString(); 769 Handle<String> GetString();
769 770
770 JsonScanner scanner_; 771 JsonScanner scanner_;
771 bool stack_overflow_; 772 bool stack_overflow_;
772 }; 773 };
773 } } // namespace v8::internal 774 } } // namespace v8::internal
774 775
775 #endif // V8_PARSER_H_ 776 #endif // V8_PARSER_H_
OLDNEW
« no previous file with comments | « src/messages.js ('k') | src/parser.cc » ('j') | src/parser.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698