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

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

Issue 11092003: Implement part-of directive. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge
Patch Set: Update co19 status for dart2dart Created 8 years, 2 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: dart/lib/compiler/implementation/scanner/listener.dart
diff --git a/dart/lib/compiler/implementation/scanner/listener.dart b/dart/lib/compiler/implementation/scanner/listener.dart
index 2017961c5a8ed5f4ebd4e522d21fd37284dceb12..55d6172eacd1df540d41828e9b2330e4e92bc9c4 100644
--- a/dart/lib/compiler/implementation/scanner/listener.dart
+++ b/dart/lib/compiler/implementation/scanner/listener.dart
@@ -691,7 +691,11 @@ class ElementListener extends Listener {
void endPartOf(Token partKeyword, Token semicolon) {
Expression name = popNode();
- addLibraryTag(new PartOf(partKeyword, name));
+ addPartOfTag(new PartOf(partKeyword, name));
+ }
+
+ void addPartOfTag(PartOf tag) {
+ compilationUnitElement.setPartOf(tag, listener);
}
void endScriptTag(bool hasPrefix, Token beginToken, Token endToken) {
@@ -1104,6 +1108,10 @@ class NodeListener extends ElementListener {
pushNode(tag);
}
+ void addPartOfTag(PartOf tag) {
+ pushNode(tag);
+ }
+
void endArgumentDefinitionTest(Token beginToken, Token endToken) {
pushNode(new Send.prefix(popNode(), new Operator(beginToken)));
}

Powered by Google App Engine
This is Rietveld 408576698