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

Side by Side Diff: runtime/vm/scanner.h

Issue 11411092: Revert "Add some support for the code-point code-unit distinction." (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 1 month 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 | « runtime/vm/object_test.cc ('k') | runtime/vm/scanner.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 // 4 //
5 // Scanner class for the Dart language. The scanner reads source text 5 // Scanner class for the Dart language. The scanner reads source text
6 // and produces a stream of tokens which is used by the parser. 6 // and produces a stream of tokens which is used by the parser.
7 // 7 //
8 8
9 #ifndef VM_SCANNER_H_ 9 #ifndef VM_SCANNER_H_
10 #define VM_SCANNER_H_ 10 #define VM_SCANNER_H_
(...skipping 28 matching lines...) Expand all
39 int offset; // Offset in source string. 39 int offset; // Offset in source string.
40 int length; // Length of token in source. 40 int length; // Length of token in source.
41 SourcePosition position; // Text position in source. 41 SourcePosition position; // Text position in source.
42 String* literal; // Identifier, number or string literal. 42 String* literal; // Identifier, number or string literal.
43 }; 43 };
44 44
45 // Dummy token index reflecting an unknown source position. 45 // Dummy token index reflecting an unknown source position.
46 static const intptr_t kDummyTokenIndex = 0; 46 static const intptr_t kDummyTokenIndex = 0;
47 47
48 // Character used to indicate a private identifier. 48 // Character used to indicate a private identifier.
49 static const unsigned char kPrivateIdentifierStart = '_'; 49 static const char kPrivateIdentifierStart = '_';
50 50
51 // Character used to separate the private identifier from the key. 51 // Character used to separate the private identifier from the key.
52 static const char kPrivateKeySeparator = '@'; 52 static const char kPrivateKeySeparator = '@';
53 53
54 typedef ZoneGrowableArray<TokenDescriptor> GrowableTokenStream; 54 typedef ZoneGrowableArray<TokenDescriptor> GrowableTokenStream;
55 55
56 // Initializes scanner to scan string source. 56 // Initializes scanner to scan string source.
57 Scanner(const String& source, const String& private_key); 57 Scanner(const String& source, const String& private_key);
58 ~Scanner(); 58 ~Scanner();
59 59
(...skipping 163 matching lines...) Expand 10 before | Expand all | Expand 10 after
223 223
224 SourcePosition c0_pos_; // Source position of lookahead character c0_. 224 SourcePosition c0_pos_; // Source position of lookahead character c0_.
225 KeywordTable keywords_[Token::numKeywords]; 225 KeywordTable keywords_[Token::numKeywords];
226 Array& keyword_symbol_table_; // Access to keyword symbols in object store. 226 Array& keyword_symbol_table_; // Access to keyword symbols in object store.
227 }; 227 };
228 228
229 229
230 } // namespace dart 230 } // namespace dart
231 231
232 #endif // VM_SCANNER_H_ 232 #endif // VM_SCANNER_H_
OLDNEW
« no previous file with comments | « runtime/vm/object_test.cc ('k') | runtime/vm/scanner.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698