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

Unified Diff: utils/pub/version_solver.dart

Issue 10854191: Require two type arguments for map literals (issue 4522). (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 years, 4 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 | « utils/pub/source_registry.dart ('k') | utils/pub/yaml/composer.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: utils/pub/version_solver.dart
===================================================================
--- utils/pub/version_solver.dart (revision 10860)
+++ utils/pub/version_solver.dart (working copy)
@@ -73,7 +73,7 @@
VersionSolver(SourceRegistry sources, this._root, this.lockFile)
: _sources = sources,
_pubspecs = new PubspecCache(sources),
- _packages = <Dependency>{},
+ _packages = <String, Dependency>{},
_work = new Queue<WorkItem>();
Future<List<PackageId>> solve() {
@@ -236,12 +236,13 @@
Version version) {
// If there is no version, it means no package, so no dependencies.
if (version == null) {
- return new Future<Map<String, PackageRef>>.immediate(<PackageRef>{});
+ return
+ new Future<Map<String, PackageRef>>.immediate(<String, PackageRef>{});
}
var id = new PackageId(source, version, description);
return solver._pubspecs.load(id).transform((pubspec) {
- var dependencies = <PackageRef>{};
+ var dependencies = <String, PackageRef>{};
for (var dependency in pubspec.dependencies) {
dependencies[dependency.name] = dependency;
}
@@ -470,7 +471,7 @@
}
Dependency(this.name)
- : _refs = <PackageRef>{};
+ : _refs = <String, PackageRef>{};
/**
* Places [ref] as a constraint from [package] onto this.
« no previous file with comments | « utils/pub/source_registry.dart ('k') | utils/pub/yaml/composer.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698