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

Unified Diff: sdk/lib/_internal/pub/lib/src/pubspec.dart

Issue 494803003: Use the version solver when choosing a version for pub global activate. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Code review changes Created 6 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
Index: sdk/lib/_internal/pub/lib/src/pubspec.dart
diff --git a/sdk/lib/_internal/pub/lib/src/pubspec.dart b/sdk/lib/_internal/pub/lib/src/pubspec.dart
index 2ab26b21cdf4731023598d3124e9e0775b1f43c2..7aa573503dbd3d1127a07f07703530f8d6c678e7 100644
--- a/sdk/lib/_internal/pub/lib/src/pubspec.dart
+++ b/sdk/lib/_internal/pub/lib/src/pubspec.dart
@@ -266,11 +266,23 @@ class Pubspec {
expectedName: expectedName, location: pubspecUri);
}
- Pubspec(this._name, this._version, this._dependencies, this._devDependencies,
- this._dependencyOverrides, this._environment, this._transformers,
- [Map fields])
- : this.fields = fields == null ? new YamlMap() : fields,
- _sources = null;
+ Pubspec(this._name, {Version version, Iterable<PackageDep> dependencies,
+ Iterable<PackageDep> devDependencies,
+ Iterable<PackageDep> dependencyOverrides,
+ VersionConstraint sdkConstraint,
+ Iterable<Iterable<TransformerConfig>> transformers,
+ Map fields, SourceRegistry sources})
+ : _version = version,
+ _dependencies = dependencies == null ? null : dependencies.toList(),
+ _devDependencies = devDependencies == null ? null :
+ devDependencies.toList(),
+ _dependencyOverrides = dependencyOverrides == null ? null :
+ dependencyOverrides.toList(),
+ _environment = new PubspecEnvironment(sdkConstraint),
+ _transformers = transformers == null ? [] :
+ transformers.map((phase) => phase.toSet()).toList(),
+ fields = fields == null ? new YamlMap() : new YamlMap.wrap(fields),
+ _sources = sources;
Pubspec.empty()
: _sources = null,

Powered by Google App Engine
This is Rietveld 408576698