File tree 6 files changed +8
-8
lines changed
crates/resolver-tests/src
6 files changed +8
-8
lines changed Original file line number Diff line number Diff line change @@ -143,7 +143,7 @@ pub fn resolve_with_global_context_raw(
143
143
for summary in self . list . iter ( ) {
144
144
let matched = match kind {
145
145
QueryKind :: Exact => dep. matches ( summary) ,
146
- QueryKind :: AlternativeVersions => dep. matches ( summary) ,
146
+ QueryKind :: RejectedVersions => dep. matches ( summary) ,
147
147
QueryKind :: AlternativeNames => true ,
148
148
QueryKind :: Normalized => true ,
149
149
} ;
Original file line number Diff line number Diff line change @@ -305,7 +305,7 @@ pub(super) fn activation_error(
305
305
} else {
306
306
// Maybe something is wrong with the available versions
307
307
let mut version_candidates = loop {
308
- match registry. query_vec ( & new_dep, QueryKind :: AlternativeVersions ) {
308
+ match registry. query_vec ( & new_dep, QueryKind :: RejectedVersions ) {
309
309
Poll :: Ready ( Ok ( candidates) ) => break candidates,
310
310
Poll :: Ready ( Err ( e) ) => return to_resolve_err ( e) ,
311
311
Poll :: Pending => match registry. block_until_ready ( ) {
Original file line number Diff line number Diff line change @@ -108,7 +108,7 @@ impl<'gctx> Source for DirectorySource<'gctx> {
108
108
}
109
109
let packages = self . packages . values ( ) . map ( |p| & p. 0 ) ;
110
110
let matches = packages. filter ( |pkg| match kind {
111
- QueryKind :: Exact | QueryKind :: AlternativeVersions => dep. matches ( pkg. summary ( ) ) ,
111
+ QueryKind :: Exact | QueryKind :: RejectedVersions => dep. matches ( pkg. summary ( ) ) ,
112
112
QueryKind :: AlternativeNames => true ,
113
113
QueryKind :: Normalized => dep. matches ( pkg. summary ( ) ) ,
114
114
} ) ;
Original file line number Diff line number Diff line change @@ -145,7 +145,7 @@ impl<'gctx> Source for PathSource<'gctx> {
145
145
self . load ( ) ?;
146
146
if let Some ( s) = self . package . as_ref ( ) . map ( |p| p. summary ( ) ) {
147
147
let matched = match kind {
148
- QueryKind :: Exact | QueryKind :: AlternativeVersions => dep. matches ( s) ,
148
+ QueryKind :: Exact | QueryKind :: RejectedVersions => dep. matches ( s) ,
149
149
QueryKind :: AlternativeNames => true ,
150
150
QueryKind :: Normalized => dep. matches ( s) ,
151
151
} ;
@@ -332,7 +332,7 @@ impl<'gctx> Source for RecursivePathSource<'gctx> {
332
332
. map ( |p| p. summary ( ) )
333
333
{
334
334
let matched = match kind {
335
- QueryKind :: Exact | QueryKind :: AlternativeVersions => dep. matches ( s) ,
335
+ QueryKind :: Exact | QueryKind :: RejectedVersions => dep. matches ( s) ,
336
336
QueryKind :: AlternativeNames => true ,
337
337
QueryKind :: Normalized => dep. matches ( s) ,
338
338
} ;
Original file line number Diff line number Diff line change @@ -799,7 +799,7 @@ impl<'gctx> Source for RegistrySource<'gctx> {
799
799
. index
800
800
. query_inner( dep. package_name( ) , & req, & mut * self . ops, & mut |s| {
801
801
let matched = match kind {
802
- QueryKind :: Exact | QueryKind :: AlternativeVersions => {
802
+ QueryKind :: Exact | QueryKind :: RejectedVersions => {
803
803
if req. is_precise( ) && self . gctx. cli_unstable( ) . unstable_options {
804
804
dep. matches_prerelease( s. as_summary( ) )
805
805
} else {
@@ -816,7 +816,7 @@ impl<'gctx> Source for RegistrySource<'gctx> {
816
816
// leak through if they're in a whitelist (aka if they were
817
817
// previously in `Cargo.lock`
818
818
match s {
819
- s @ _ if kind == QueryKind :: AlternativeVersions => callback( s) ,
819
+ s @ _ if kind == QueryKind :: RejectedVersions => callback( s) ,
820
820
s @ IndexSummary :: Candidate ( _) => callback( s) ,
821
821
s @ IndexSummary :: Yanked ( _) => {
822
822
if self . yanked_whitelist. contains( & s. package_id( ) ) {
Original file line number Diff line number Diff line change @@ -184,7 +184,7 @@ pub enum QueryKind {
184
184
///
185
185
/// Path/Git sources may return all dependencies that are at that URI,
186
186
/// whereas an `Registry` source may return dependencies that are yanked or invalid.
187
- AlternativeVersions ,
187
+ RejectedVersions ,
188
188
/// A query for packages close to the given dependency requirement.
189
189
///
190
190
/// Each source gets to define what `close` means for it.
You can’t perform that action at this time.
0 commit comments