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

Unified Diff: compiler/java/com/google/dart/compiler/parser/DartParser.java

Issue 10832321: Issue 4048. Support for revised library/import syntax (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 4 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: compiler/java/com/google/dart/compiler/parser/DartParser.java
diff --git a/compiler/java/com/google/dart/compiler/parser/DartParser.java b/compiler/java/com/google/dart/compiler/parser/DartParser.java
index 017970f664520d3dc738dfb90c4e6fb8dfaa5ea5..3065b1cf2dea7d57bbadb6fe50beb480fa08036f 100644
--- a/compiler/java/com/google/dart/compiler/parser/DartParser.java
+++ b/compiler/java/com/google/dart/compiler/parser/DartParser.java
@@ -409,8 +409,7 @@ public class DartParser extends CompletionHooksParserBase {
LibraryNode importPath;
if (importDirective.getPrefix() != null) {
importPath =
- new LibraryNode(importDirective.getLibraryUri().getValue(), importDirective.getPrefix()
- .getName());
+ new LibraryNode(importDirective);
} else {
importPath = new LibraryNode(importDirective.getLibraryUri().getValue());
}
@@ -442,8 +441,7 @@ public class DartParser extends CompletionHooksParserBase {
LibraryNode importPath;
if (importDirective.getOldPrefix() != null) {
importPath =
- new LibraryNode(importDirective.getLibraryUri().getValue(), importDirective.getOldPrefix()
- .getValue());
+ new LibraryNode(importDirective);
} else {
importPath = new LibraryNode(importDirective.getLibraryUri().getValue());
}
@@ -589,7 +587,6 @@ public class DartParser extends CompletionHooksParserBase {
boolean export = false;
if (optional(Token.BIT_AND)) {
if (optionalPseudoKeyword(EXPORT_KEYWORD)) {
- next();
export = true;
} else {
reportError(position(), ParserErrorCode.EXPECTED_EXPORT);

Powered by Google App Engine
This is Rietveld 408576698