OLD | NEW |
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 154 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
165 // Read the characters of a string literal. | 165 // Read the characters of a string literal. |
166 void ScanLiteralStringChars(bool is_raw); | 166 void ScanLiteralStringChars(bool is_raw); |
167 | 167 |
168 // Reads a fixed number of hexadecimal digits. | 168 // Reads a fixed number of hexadecimal digits. |
169 bool ScanHexDigits(int digits, uint32_t* value); | 169 bool ScanHexDigits(int digits, uint32_t* value); |
170 | 170 |
171 // Reads a variable number of hexadecimal digits. | 171 // Reads a variable number of hexadecimal digits. |
172 bool ScanHexDigits(int min_digits, int max_digits, uint32_t* value); | 172 bool ScanHexDigits(int min_digits, int max_digits, uint32_t* value); |
173 | 173 |
174 // Reads an escaped code point from within a string literal. | 174 // Reads an escaped code point from within a string literal. |
175 bool ScanEscapedCodePoint(uint32_t* escaped_char); | 175 void ScanEscapedCodePoint(uint32_t* escaped_char); |
176 | 176 |
177 // Reads identifier. | 177 // Reads identifier. |
178 RawString* ConsumeIdentChars(bool allow_dollar); | 178 RawString* ConsumeIdentChars(bool allow_dollar); |
179 void ScanIdentChars(bool allow_dollar); | 179 void ScanIdentChars(bool allow_dollar); |
180 void ScanIdent() { | 180 void ScanIdent() { |
181 ScanIdentChars(true); | 181 ScanIdentChars(true); |
182 } | 182 } |
183 void ScanIdentNoDollar() { | 183 void ScanIdentNoDollar() { |
184 ScanIdentChars(false); | 184 ScanIdentChars(false); |
185 } | 185 } |
(...skipping 25 matching lines...) Expand all Loading... |
211 | 211 |
212 SourcePosition c0_pos_; // Source position of lookahead character c0_. | 212 SourcePosition c0_pos_; // Source position of lookahead character c0_. |
213 KeywordTable keywords_[Token::numKeywords]; | 213 KeywordTable keywords_[Token::numKeywords]; |
214 Array& keyword_symbol_table_; // Access to keyword symbols in object store. | 214 Array& keyword_symbol_table_; // Access to keyword symbols in object store. |
215 }; | 215 }; |
216 | 216 |
217 | 217 |
218 } // namespace dart | 218 } // namespace dart |
219 | 219 |
220 #endif // VM_SCANNER_H_ | 220 #endif // VM_SCANNER_H_ |
OLD | NEW |