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

Side by Side Diff: pkg/analyzer_plugin/tool/spec/codegen_matchers.dart

Issue 3002293003: Convert GeneratedContent to async and use AnalysisDriver for tasks graph. (Closed)
Patch Set: Created 3 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2014, 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 /** 5 /**
6 * Code generation for the file "matchers.dart". 6 * Code generation for the file "matchers.dart".
7 */ 7 */
8 import 'dart:convert'; 8 import 'dart:convert';
9 9
10 import 'package:analyzer/src/codegen/tools.dart'; 10 import 'package:analyzer/src/codegen/tools.dart';
11 11
12 import 'api.dart'; 12 import 'api.dart';
13 import 'from_html.dart'; 13 import 'from_html.dart';
14 import 'implied_types.dart'; 14 import 'implied_types.dart';
15 import 'to_html.dart'; 15 import 'to_html.dart';
16 16
17 final GeneratedFile target = new GeneratedFile( 17 final GeneratedFile target = new GeneratedFile(
18 'test/integration/support/protocol_matchers.dart', (String pkgPath) { 18 'test/integration/support/protocol_matchers.dart', (String pkgPath) async {
19 CodegenMatchersVisitor visitor = new CodegenMatchersVisitor(readApi(pkgPath)); 19 CodegenMatchersVisitor visitor = new CodegenMatchersVisitor(readApi(pkgPath));
20 return visitor.collectCode(visitor.visitApi); 20 return visitor.collectCode(visitor.visitApi);
21 }); 21 });
22 22
23 class CodegenMatchersVisitor extends HierarchicalApiVisitor with CodeGenerator { 23 class CodegenMatchersVisitor extends HierarchicalApiVisitor with CodeGenerator {
24 /** 24 /**
25 * Visitor used to produce doc comments. 25 * Visitor used to produce doc comments.
26 */ 26 */
27 final ToHtmlVisitor toHtmlVisitor; 27 final ToHtmlVisitor toHtmlVisitor;
28 28
(...skipping 152 matching lines...) Expand 10 before | Expand all | Expand 10 after
181 for (TypeDecl choice in typeUnion.choices) { 181 for (TypeDecl choice in typeUnion.choices) {
182 if (commaNeeded) { 182 if (commaNeeded) {
183 write(', '); 183 write(', ');
184 } 184 }
185 visitTypeDecl(choice); 185 visitTypeDecl(choice);
186 commaNeeded = true; 186 commaNeeded = true;
187 } 187 }
188 write('])'); 188 write('])');
189 } 189 }
190 } 190 }
OLDNEW
« no previous file with comments | « pkg/analyzer_plugin/tool/spec/codegen_inttest_methods.dart ('k') | pkg/analyzer_plugin/tool/spec/codegen_protocol_common.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698