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

Side by Side Diff: src/token.h

Issue 9422001: Make 'module' a context-sensitive keyword. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Added missing CHECK_OK; rebased. Created 8 years, 10 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
OLDNEW
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 155 matching lines...) Expand 10 before | Expand all | Expand 10 after
166 /* Identifiers (not keywords or future reserved words). */ \ 166 /* Identifiers (not keywords or future reserved words). */ \
167 T(IDENTIFIER, NULL, 0) \ 167 T(IDENTIFIER, NULL, 0) \
168 \ 168 \
169 /* Future reserved words (ECMA-262, section 7.6.1.2). */ \ 169 /* Future reserved words (ECMA-262, section 7.6.1.2). */ \
170 T(FUTURE_RESERVED_WORD, NULL, 0) \ 170 T(FUTURE_RESERVED_WORD, NULL, 0) \
171 T(FUTURE_STRICT_RESERVED_WORD, NULL, 0) \ 171 T(FUTURE_STRICT_RESERVED_WORD, NULL, 0) \
172 K(CONST, "const", 0) \ 172 K(CONST, "const", 0) \
173 K(EXPORT, "export", 0) \ 173 K(EXPORT, "export", 0) \
174 K(IMPORT, "import", 0) \ 174 K(IMPORT, "import", 0) \
175 K(LET, "let", 0) \ 175 K(LET, "let", 0) \
176 K(MODULE, "module", 0) \
177 \ 176 \
178 /* Illegal token - not able to scan. */ \ 177 /* Illegal token - not able to scan. */ \
179 T(ILLEGAL, "ILLEGAL", 0) \ 178 T(ILLEGAL, "ILLEGAL", 0) \
180 \ 179 \
181 /* Scanner-internal use only. */ \ 180 /* Scanner-internal use only. */ \
182 T(WHITESPACE, NULL, 0) 181 T(WHITESPACE, NULL, 0)
183 182
184 183
185 class Token { 184 class Token {
186 public: 185 public:
(...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after
288 private: 287 private:
289 static const char* const name_[NUM_TOKENS]; 288 static const char* const name_[NUM_TOKENS];
290 static const char* const string_[NUM_TOKENS]; 289 static const char* const string_[NUM_TOKENS];
291 static const int8_t precedence_[NUM_TOKENS]; 290 static const int8_t precedence_[NUM_TOKENS];
292 static const char token_type[NUM_TOKENS]; 291 static const char token_type[NUM_TOKENS];
293 }; 292 };
294 293
295 } } // namespace v8::internal 294 } } // namespace v8::internal
296 295
297 #endif // V8_TOKEN_H_ 296 #endif // V8_TOKEN_H_
OLDNEW
« src/parser.cc ('K') | « src/scanner.cc ('k') | test/mjsunit/harmony/module-parsing.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698