Skip to content

Commit 3f57f13

Browse files
committed
enable default bounds
1 parent 70506d2 commit 3f57f13

File tree

8 files changed

+7
-130
lines changed

8 files changed

+7
-130
lines changed

compiler/rustc_hir_analysis/src/astconv/bounds.rs

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -49,9 +49,7 @@ impl<'tcx> dyn AstConv<'tcx> + '_ {
4949
let tcx = self.tcx();
5050
let trait_id = tcx.lang_items().get(trait_);
5151

52-
if self.check_for_implicit_trait(trait_id, ast_bounds, self_ty_where_predicates)
53-
&& (trait_ == hir::LangItem::Sized || tcx.features().default_auto_traits)
54-
{
52+
if self.check_for_implicit_trait(trait_id, ast_bounds, self_ty_where_predicates) {
5553
// There was no `?Trait` or `!Trait` bound;
5654
// add `Trait` if it's available.
5755
bounds.push_lang_item_trait(tcx, self_ty, trait_, span);

compiler/rustc_hir_analysis/src/astconv/object_safety.rs

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -54,13 +54,11 @@ impl<'o, 'tcx> dyn AstConv<'tcx> + 'o {
5454
}
5555
}
5656
// FIXME: support polarity for trait objects
57-
if tcx.features().default_auto_traits {
58-
hir::lang_items::DEFAULT_TRAITS.iter().for_each(|default_trait| {
59-
if *default_trait != hir::LangItem::Sized {
60-
bounds.push_lang_item_trait(tcx, dummy_self, *default_trait, span);
61-
}
62-
});
63-
}
57+
hir::lang_items::DEFAULT_TRAITS.iter().for_each(|default_trait| {
58+
if *default_trait != hir::LangItem::Sized {
59+
bounds.push_lang_item_trait(tcx, dummy_self, *default_trait, span);
60+
}
61+
});
6462

6563
let mut trait_bounds = vec![];
6664
let mut projection_bounds = vec![];

src/tools/tidy/src/ui_tests.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ use std::path::{Path, PathBuf};
1414
// #73494.
1515
const ENTRY_LIMIT: usize = 900;
1616
// FIXME: The following limits should be reduced eventually.
17-
const ISSUES_ENTRY_LIMIT: usize = 1819;
17+
const ISSUES_ENTRY_LIMIT: usize = 1816;
1818
const ROOT_ENTRY_LIMIT: usize = 871;
1919

2020
const EXPECTED_TEST_FILE_EXTENSIONS: &[&str] = &[

tests/ui/issues/issue-29147-rpass.rs

Lines changed: 0 additions & 28 deletions
This file was deleted.

tests/ui/issues/issue-29147.rs

Lines changed: 0 additions & 23 deletions
This file was deleted.

tests/ui/issues/issue-29147.stderr

Lines changed: 0 additions & 17 deletions
This file was deleted.

tests/ui/traits/next-solver/cycles/coinduction/fixpoint-exponential-growth.rs

Lines changed: 0 additions & 35 deletions
This file was deleted.

tests/ui/traits/next-solver/cycles/coinduction/fixpoint-exponential-growth.stderr

Lines changed: 0 additions & 16 deletions
This file was deleted.

0 commit comments

Comments
 (0)