@@ -65,7 +65,7 @@ pub enum PixiSpec {
65
65
66
66
/// The spec is represented by a detailed version spec. The package should
67
67
/// be retrieved from a channel.
68
- DetailedVersion ( DetailedSpec ) ,
68
+ DetailedVersion ( Box < DetailedSpec > ) ,
69
69
70
70
/// The spec is represented as an archive that can be downloaded from the
71
71
/// specified URL. The package should be retrieved from the URL and can
@@ -117,7 +117,7 @@ impl PixiSpec {
117
117
{
118
118
Self :: Version ( spec. version . unwrap_or ( VersionSpec :: Any ) )
119
119
} else {
120
- Self :: DetailedVersion ( DetailedSpec {
120
+ Self :: DetailedVersion ( Box :: new ( DetailedSpec {
121
121
version : spec. version ,
122
122
build : spec. build ,
123
123
build_number : spec. build_number ,
@@ -129,7 +129,7 @@ impl PixiSpec {
129
129
subdir : spec. subdir ,
130
130
md5 : spec. md5 ,
131
131
sha256 : spec. sha256 ,
132
- } )
132
+ } ) )
133
133
}
134
134
}
135
135
@@ -189,17 +189,15 @@ impl PixiSpec {
189
189
pub fn into_version ( self ) -> Option < VersionSpec > {
190
190
match self {
191
191
Self :: Version ( v) => Some ( v) ,
192
- Self :: DetailedVersion ( DetailedSpec {
193
- version : Some ( v) , ..
194
- } ) => Some ( v) ,
192
+ Self :: DetailedVersion ( v) => v. version ,
195
193
_ => None ,
196
194
}
197
195
}
198
196
199
197
/// Converts this instance into a [`DetailedSpec`] if possible.
200
198
pub fn into_detailed ( self ) -> Option < DetailedSpec > {
201
199
match self {
202
- Self :: DetailedVersion ( v) => Some ( v) ,
200
+ Self :: DetailedVersion ( v) => Some ( * v) ,
203
201
Self :: Version ( v) => Some ( DetailedSpec {
204
202
version : Some ( v) ,
205
203
..DetailedSpec :: default ( )
@@ -351,7 +349,7 @@ impl From<SourceSpec> for PixiSpec {
351
349
352
350
impl From < DetailedSpec > for PixiSpec {
353
351
fn from ( value : DetailedSpec ) -> Self {
354
- Self :: DetailedVersion ( value)
352
+ Self :: DetailedVersion ( Box :: new ( value) )
355
353
}
356
354
}
357
355
@@ -407,7 +405,7 @@ pub enum BinarySpec {
407
405
408
406
/// The spec is represented by a detailed version spec. The package should
409
407
/// be retrieved from a channel.
410
- DetailedVersion ( DetailedSpec ) ,
408
+ DetailedVersion ( Box < DetailedSpec > ) ,
411
409
412
410
/// The spec is represented as an archive that can be downloaded from the
413
411
/// specified URL. The package should be retrieved from the URL and can
0 commit comments