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

Side by Side Diff: pkg/csslib/lib/src/tree_printer.dart

Issue 64993002: pkg/csslib: fix analyzer issue (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 1 month 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, 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 part of csslib.visitor; 5 part of csslib.visitor;
6 6
7 // TODO(terry): Enable class for debug only; when conditional imports enabled. 7 // TODO(terry): Enable class for debug only; when conditional imports enabled.
8 8
9 /** Helper function to dump the CSS AST. */ 9 /** Helper function to dump the CSS AST. */
10 String treeToDebugString(StyleSheet styleSheet, [bool useSpan = false]) { 10 String treeToDebugString(StyleSheet styleSheet, [bool useSpan = false]) {
(...skipping 154 matching lines...) Expand 10 before | Expand all | Expand 10 after
165 visitDeclarationGroup(node.declarations); 165 visitDeclarationGroup(node.declarations);
166 output.depth--; 166 output.depth--;
167 } 167 }
168 168
169 /** 169 /**
170 * Added optional newLine for handling @include at top-level vs/ inside of 170 * Added optional newLine for handling @include at top-level vs/ inside of
171 * a declaration group. 171 * a declaration group.
172 */ 172 */
173 void visitIncludeDirective(IncludeDirective node) { 173 void visitIncludeDirective(IncludeDirective node) {
174 heading('IncludeDirective ${node.name}', node); 174 heading('IncludeDirective ${node.name}', node);
175 output.writeNodeList('parameters', node.args); 175 var flattened = node.args.expand((e) => e).toList();
176 output.writeNodeList('parameters', flattened);
176 } 177 }
177 178
178 void visitIncludeMixinAtDeclaration(IncludeMixinAtDeclaration node) { 179 void visitIncludeMixinAtDeclaration(IncludeMixinAtDeclaration node) {
179 heading('IncludeMixinAtDeclaration ${node.include.name}', node); 180 heading('IncludeMixinAtDeclaration ${node.include.name}', node);
180 output.depth++; 181 output.depth++;
181 visitIncludeDirective(node.include); 182 visitIncludeDirective(node.include);
182 output.depth--; 183 output.depth--;
183 } 184 }
184 185
185 void visitExtendDeclaration(ExtendDeclaration node) { 186 void visitExtendDeclaration(ExtendDeclaration node) {
(...skipping 362 matching lines...) Expand 10 before | Expand all | Expand 10 after
548 } 549 }
549 550
550 void visitPaddingExpression(PaddingExpression node) { 551 void visitPaddingExpression(PaddingExpression node) {
551 heading('Dart Style PaddingExpression', node); 552 heading('Dart Style PaddingExpression', node);
552 } 553 }
553 554
554 void visitWidthExpression(WidthExpression node) { 555 void visitWidthExpression(WidthExpression node) {
555 heading('Dart Style WidthExpression', node); 556 heading('Dart Style WidthExpression', node);
556 } 557 }
557 } 558 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698