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

Unified Diff: lib/compiler/implementation/scanner/token.dart

Issue 10915122: Fix source locations for inlined and patched functions. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Address comments. Created 8 years, 3 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 side-by-side diff with in-line comments
Download patch
Index: lib/compiler/implementation/scanner/token.dart
diff --git a/lib/compiler/implementation/scanner/token.dart b/lib/compiler/implementation/scanner/token.dart
index 02102c62c072186a47f1cbe510ce2098f74cdd6d..86ef6d8cc4c934000910398f15f32eab037ecebf 100644
--- a/lib/compiler/implementation/scanner/token.dart
+++ b/lib/compiler/implementation/scanner/token.dart
@@ -124,6 +124,12 @@ class Token {
*/
int get precedence => info.precedence;
+ bool isIdentifier() {
+ if (kind === IDENTIFIER_TOKEN) return true;
+ if (kind === KEYWORD_TOKEN) return value.isPseudo;
+ return false;
+ }
+
/**
* Returns a textual representation of this token to be used for debugging
* purposes. The resulting string might contain information about the
« no previous file with comments | « lib/compiler/implementation/scanner/parser.dart ('k') | lib/compiler/implementation/source_map_builder.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698