File tree 1 file changed +4
-3
lines changed
compiler/rustc_trait_selection/src/traits/select
1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -1769,6 +1769,7 @@ impl<'tcx> SelectionContext<'_, 'tcx> {
1769
1769
/// *fairly arbitrary* choices about which candidate is actually used.
1770
1770
///
1771
1771
/// For more details, look at the implementation of this method :)
1772
+ #[ instrument( level = "debug" , skip( self ) , ret) ]
1772
1773
fn winnow_candidates (
1773
1774
& mut self ,
1774
1775
has_non_region_infer : bool ,
@@ -1854,7 +1855,7 @@ impl<'tcx> SelectionContext<'_, 'tcx> {
1854
1855
match alias_bound {
1855
1856
Some ( Some ( index) ) => return Some ( ProjectionCandidate ( index) ) ,
1856
1857
Some ( None ) => { }
1857
- None => { }
1858
+ None => return None ,
1858
1859
}
1859
1860
1860
1861
// Need to prioritize builtin trait object impls as `<dyn Any as Any>::type_id`
@@ -1868,8 +1869,8 @@ impl<'tcx> SelectionContext<'_, 'tcx> {
1868
1869
. try_reduce ( |c1, c2| if has_non_region_infer { None } else { Some ( c1. min ( c2) ) } ) ;
1869
1870
match object_bound {
1870
1871
Some ( Some ( index) ) => return Some ( ObjectCandidate ( index) ) ,
1871
- Some ( None ) => return None ,
1872
- None => { }
1872
+ Some ( None ) => { }
1873
+ None => return None ,
1873
1874
}
1874
1875
1875
1876
// Finally, handle overlapping user-written impls.
You can’t perform that action at this time.
0 commit comments