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

Unified Diff: pkg/compiler/lib/src/tree/prettyprint.dart

Issue 1859343004: dartfmt pkg/compiler (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 4 years, 8 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
« no previous file with comments | « pkg/compiler/lib/src/tree/nodes.dart ('k') | pkg/compiler/lib/src/tree/unparser.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/compiler/lib/src/tree/prettyprint.dart
diff --git a/pkg/compiler/lib/src/tree/prettyprint.dart b/pkg/compiler/lib/src/tree/prettyprint.dart
index 1b17b7ab75dded52c39e54fa190996f2e88855d5..0fc2fa574323d806a84c7365db1278097699e69b 100644
--- a/pkg/compiler/lib/src/tree/prettyprint.dart
+++ b/pkg/compiler/lib/src/tree/prettyprint.dart
@@ -47,8 +47,7 @@ class PrettyPrinter extends Indentation with Tagging<Node> implements Visitor {
visitAsyncModifier(AsyncModifier node) {
openAndCloseNode(node, "AsyncModifier",
- {'asyncToken': node.asyncToken,
- 'starToken': node.starToken});
+ {'asyncToken': node.asyncToken, 'starToken': node.starToken});
}
visitBlock(Block node) {
@@ -76,9 +75,8 @@ class PrettyPrinter extends Indentation with Tagging<Node> implements Visitor {
}
visitClassNode(ClassNode node) {
- openNode(node, "ClassNode", {
- "extendsKeyword" : tokenToStringOrNull(node.extendsKeyword)
- });
+ openNode(node, "ClassNode",
+ {"extendsKeyword": tokenToStringOrNull(node.extendsKeyword)});
visitChildNode(node.name, "name");
visitChildNode(node.superclass, "superclass");
visitChildNode(node.interfaces, "interfaces");
@@ -139,9 +137,8 @@ class PrettyPrinter extends Indentation with Tagging<Node> implements Visitor {
}
visitFunctionExpression(FunctionExpression node) {
- openNode(node, "FunctionExpression", {
- "getOrSet" : tokenToStringOrNull(node.getOrSet)
- });
+ openNode(node, "FunctionExpression",
+ {"getOrSet": tokenToStringOrNull(node.getOrSet)});
visitChildNode(node.modifiers, "modifiers");
visitChildNode(node.returnType, "returnType");
visitChildNode(node.name, "name");
@@ -152,7 +149,7 @@ class PrettyPrinter extends Indentation with Tagging<Node> implements Visitor {
}
visitIdentifier(Identifier node) {
- openAndCloseNode(node, "Identifier", {"token" : node.token});
+ openAndCloseNode(node, "Identifier", {"token": node.token});
}
visitIf(If node) {
@@ -169,7 +166,7 @@ class PrettyPrinter extends Indentation with Tagging<Node> implements Visitor {
// Custom.
printLiteral(Literal node, String type) {
- openAndCloseNode(node, type, {"value" : node.value.toString()});
+ openAndCloseNode(node, type, {"value": node.value.toString()});
}
visitLiteralBool(LiteralBool node) {
@@ -188,9 +185,8 @@ class PrettyPrinter extends Indentation with Tagging<Node> implements Visitor {
tokenToStringOrNull(Token token) => token == null ? null : token.stringValue;
visitLiteralList(LiteralList node) {
- openNode(node, "LiteralList", {
- "constKeyword" : tokenToStringOrNull(node.constKeyword)
- });
+ openNode(node, "LiteralList",
+ {"constKeyword": tokenToStringOrNull(node.constKeyword)});
visitChildNode(node.typeArguments, "typeArguments");
visitChildNode(node.elements, "elements");
closeNode();
@@ -209,8 +205,7 @@ class PrettyPrinter extends Indentation with Tagging<Node> implements Visitor {
}
visitLiteralString(LiteralString node) {
- openAndCloseNode(node, "LiteralString",
- {"value" : node.token});
+ openAndCloseNode(node, "LiteralString", {"value": node.token});
}
visitMixinApplication(MixinApplication node) {
@@ -234,7 +229,7 @@ class PrettyPrinter extends Indentation with Tagging<Node> implements Visitor {
}
visitNodeList(NodeList node) {
- var params = { "delimiter" : node.delimiter };
+ var params = {"delimiter": node.delimiter};
if (node.isEmpty) {
openAndCloseNode(node, "NodeList", params);
} else {
@@ -245,7 +240,7 @@ class PrettyPrinter extends Indentation with Tagging<Node> implements Visitor {
}
visitOperator(Operator node) {
- openAndCloseNode(node, "Operator", {"value" : node.token});
+ openAndCloseNode(node, "Operator", {"value": node.token});
}
visitParenthesizedExpression(ParenthesizedExpression node) {
@@ -287,9 +282,9 @@ class PrettyPrinter extends Indentation with Tagging<Node> implements Visitor {
openSendNodeWithFields(Send node, String type) {
openNode(node, type, {
- "isPrefix" : "${node.isPrefix}",
- "isPostfix" : "${node.isPostfix}",
- "isIndex" : "${node.isIndex}"
+ "isPrefix": "${node.isPrefix}",
+ "isPostfix": "${node.isPostfix}",
+ "isIndex": "${node.isIndex}"
});
visitChildNode(node.receiver, "receiver");
visitChildNode(node.selector, "selector");
@@ -376,16 +371,14 @@ class PrettyPrinter extends Indentation with Tagging<Node> implements Visitor {
}
visitMetadata(Metadata node) {
- openNode(node, "Metadata", {
- "token": node.token
- });
+ openNode(node, "Metadata", {"token": node.token});
visitChildNode(node.expression, "expression");
closeNode();
}
visitCombinator(Combinator node) {
- openNode(node, "Combinator", {"isShow" : "${node.isShow}",
- "isHide" : "${node.isHide}"});
+ openNode(node, "Combinator",
+ {"isShow": "${node.isShow}", "isHide": "${node.isHide}"});
closeNode();
}
@@ -400,8 +393,7 @@ class PrettyPrinter extends Indentation with Tagging<Node> implements Visitor {
}
visitImport(Import node) {
- openNode(node, "Import", {
- "isDeferred" : "${node.isDeferred}"});
+ openNode(node, "Import", {"isDeferred": "${node.isDeferred}"});
visitChildNode(node.uri, "uri");
if (node.conditionalUris != null) {
visitChildNode(node.conditionalUris, "conditionalUris");
« no previous file with comments | « pkg/compiler/lib/src/tree/nodes.dart ('k') | pkg/compiler/lib/src/tree/unparser.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698