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

Unified Diff: pkg/analyzer/example/resolver_driver.dart

Issue 725143004: Format and sort analyzer and analysis_server packages. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « pkg/analyzer/example/parser_driver.dart ('k') | pkg/analyzer/example/scanner_driver.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/analyzer/example/resolver_driver.dart
diff --git a/pkg/analyzer/example/resolver_driver.dart b/pkg/analyzer/example/resolver_driver.dart
index 08e40653b3a74fbe1f65a9a52808d27c6982e0e7..0992b76644affa99530ffd52df4846b6b91fafbe 100644
--- a/pkg/analyzer/example/resolver_driver.dart
+++ b/pkg/analyzer/example/resolver_driver.dart
@@ -1,18 +1,17 @@
#!/usr/bin/env dart
-
// Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
-import 'package:analyzer/src/generated/java_io.dart';
-import 'package:analyzer/src/generated/source_io.dart';
+import 'dart:io';
+
import 'package:analyzer/src/generated/ast.dart';
-import 'package:analyzer/src/generated/sdk.dart' show DartSdk;
-import 'package:analyzer/src/generated/sdk_io.dart' show DirectoryBasedDartSdk;
import 'package:analyzer/src/generated/element.dart';
import 'package:analyzer/src/generated/engine.dart';
-
-import 'dart:io';
+import 'package:analyzer/src/generated/java_io.dart';
+import 'package:analyzer/src/generated/sdk.dart' show DartSdk;
+import 'package:analyzer/src/generated/sdk_io.dart' show DirectoryBasedDartSdk;
+import 'package:analyzer/src/generated/source_io.dart';
main(List<String> args) {
print('working dir ${new File('.').resolveSymbolicLinksSync()}');
@@ -26,7 +25,8 @@ main(List<String> args) {
DartSdk sdk = DirectoryBasedDartSdk.defaultSdk;
AnalysisContext context = AnalysisEngine.instance.createAnalysisContext();
- context.sourceFactory = new SourceFactory([new DartUriResolver(sdk), new FileUriResolver()]);
+ context.sourceFactory =
+ new SourceFactory([new DartUriResolver(sdk), new FileUriResolver()]);
Source source = new FileBasedSource.con1(new JavaFile(args[1]));
//
ChangeSet changeSet = new ChangeSet();
@@ -35,7 +35,8 @@ main(List<String> args) {
LibraryElement libElement = context.computeLibraryElement(source);
print("libElement: $libElement");
- CompilationUnit resolvedUnit = context.resolveCompilationUnit(source, libElement);
+ CompilationUnit resolvedUnit =
+ context.resolveCompilationUnit(source, libElement);
var visitor = new _ASTVisitor();
resolvedUnit.accept(visitor);
}
@@ -49,7 +50,8 @@ class _ASTVisitor extends GeneralizingAstVisitor {
text += " element: ${element.runtimeType}";
LibraryElement library = element.library;
if (library != null) {
- text += " from ${element.library.definingCompilationUnit.source.fullName}";
+ text +=
+ " from ${element.library.definingCompilationUnit.source.fullName}";
}
}
}
@@ -57,4 +59,3 @@ class _ASTVisitor extends GeneralizingAstVisitor {
return super.visitNode(node);
}
}
-
« no previous file with comments | « pkg/analyzer/example/parser_driver.dart ('k') | pkg/analyzer/example/scanner_driver.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698