Index: pkg/analyzer2dart/lib/src/driver.dart |
diff --git a/pkg/analyzer2dart/lib/src/driver.dart b/pkg/analyzer2dart/lib/src/driver.dart |
index 32daaf5ea2a89e33382f20a3e531856f3da12f5c..27488138357b9da9c8a7428cb443a06d2977ea6e 100644 |
--- a/pkg/analyzer2dart/lib/src/driver.dart |
+++ b/pkg/analyzer2dart/lib/src/driver.dart |
@@ -7,7 +7,7 @@ library analyzer2dart.driver; |
import 'package:analyzer/src/generated/element.dart'; |
import 'package:analyzer/src/generated/engine.dart'; |
import 'package:analyzer/src/generated/java_io.dart'; |
-import 'package:analyzer/src/generated/sdk_io.dart'; |
+import 'package:analyzer/src/generated/sdk.dart'; |
import 'package:analyzer/src/generated/source_io.dart'; |
import 'closed_world.dart'; |
@@ -19,12 +19,12 @@ import 'tree_shaker.dart'; |
class Driver { |
AnalysisContext context; |
- Driver() : context = AnalysisEngine.instance.createAnalysisContext() { |
+ Driver(DartSdk sdk) : context = AnalysisEngine.instance.createAnalysisContext() { |
// Set up the source factory. |
// TODO(paulberry): do we want to use ExplicitPackageUriResolver? |
List<UriResolver> uriResolvers = [ |
new FileUriResolver(), |
- new DartUriResolver(DirectoryBasedDartSdk.defaultSdk) /* , |
+ new DartUriResolver(sdk) /* , |
new PackageUriResolver(packagesDirectories) */ |
]; |
context.sourceFactory = new SourceFactory(uriResolvers); |