| 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 library fasta.scanner.token; | 5 library fasta.scanner.token; |
| 6 | 6 |
| 7 import 'keyword.dart' show | 7 import 'keyword.dart' show |
| 8 Keyword; | 8 Keyword; |
| 9 | 9 |
| 10 import 'precedence.dart' show | 10 import 'precedence.dart' show |
| (...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 107 } | 107 } |
| 108 } | 108 } |
| 109 | 109 |
| 110 /// The character offset of the end of this token within the source text. | 110 /// The character offset of the end of this token within the source text. |
| 111 int get charEnd => charOffset + charCount; | 111 int get charEnd => charOffset + charCount; |
| 112 | 112 |
| 113 bool get isEof => false; | 113 bool get isEof => false; |
| 114 } | 114 } |
| 115 | 115 |
| 116 /** | 116 /** |
| 117 * A [SymbolToken] represents the symbol in its precedence info. | 117 * A [SymbolToken] represents the symbol in its precendence info. |
| 118 * Also used for end of file with EOF_INFO. | 118 * Also used for end of file with EOF_INFO. |
| 119 */ | 119 */ |
| 120 class SymbolToken extends Token { | 120 class SymbolToken extends Token { |
| 121 final PrecedenceInfo info; | 121 final PrecedenceInfo info; |
| 122 | 122 |
| 123 SymbolToken(this.info, int charOffset) : super(charOffset); | 123 SymbolToken(this.info, int charOffset) : super(charOffset); |
| 124 | 124 |
| 125 String get value => info.value; | 125 String get value => info.value; |
| 126 | 126 |
| 127 String get stringValue => info.value; | 127 String get stringValue => info.value; |
| (...skipping 228 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 356 identical(value, "<=") || | 356 identical(value, "<=") || |
| 357 identical(value, "<") || | 357 identical(value, "<") || |
| 358 identical(value, "&") || | 358 identical(value, "&") || |
| 359 identical(value, "^") || | 359 identical(value, "^") || |
| 360 identical(value, "|"); | 360 identical(value, "|"); |
| 361 } | 361 } |
| 362 | 362 |
| 363 bool isTernaryOperator(String value) => identical(value, "[]="); | 363 bool isTernaryOperator(String value) => identical(value, "[]="); |
| 364 | 364 |
| 365 bool isMinusOperator(String value) => identical(value, "-"); | 365 bool isMinusOperator(String value) => identical(value, "-"); |
| OLD | NEW |