Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rollup of 12 pull requests #132317

Merged
merged 29 commits into from
Oct 29, 2024
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
Show all changes
29 commits
Select commit Hold shift + click to select a range
8ee548f
const fn str::is_char_boundary
zachs18 Oct 23, 2024
aa493d0
const fn str::split_at*
zachs18 Oct 23, 2024
6ab87f8
Collect item bounds for RPITITs from trait where clauses just like as…
compiler-errors Oct 26, 2024
e4f793a
riscv-soft-abi-with-float-features.rs: adapt for LLVM 20
krasimirgg Oct 28, 2024
0bff994
split clippy task for library and compiler, so different lints can be…
klensy Oct 7, 2024
746b675
fix clippy::clone_on_ref_ptr for compiler
klensy Oct 7, 2024
a946721
clarified doc for `std::fs::OpenOptions.truncate()`
yakiimoninja Oct 28, 2024
5910a4f
clarified std::fs truncate doc
yakiimoninja Oct 28, 2024
d4774ff
Remove my ping for rustdoc/clean/types.rs
camelid Oct 28, 2024
b2f335e
Split `boxed.rs` into a few modules
WaffleLapkin Oct 27, 2024
f0744ca
Bless a miri test
WaffleLapkin Oct 28, 2024
5ae5323
Remove myself from mentions inside `tests/ui/check-cfg` directory
Urgau Oct 28, 2024
8b7b8e5
Hack out effects support for old solver
compiler-errors Oct 22, 2024
1763637
correct LLVMRustCreateThinLTOData arg types
klensy Oct 27, 2024
2b326e3
correct LLVMRustDIBuilderCreateOpLLVMFragment return type
klensy Oct 27, 2024
6c93c65
Delete `tests/crashes/23707.rs` because it's flaky
jieyouxu Oct 29, 2024
6f82a95
Rename `command-list.rs` to `directive-list.rs`
Zalathar Oct 29, 2024
5d0f52e
Rollup merge of #131375 - klensy:clone_on_ref_ptr, r=cjgillot
workingjubilee Oct 29, 2024
b496974
Rollup merge of #131520 - zachs18:const-str-split, r=Noratrieb
workingjubilee Oct 29, 2024
e97286e
Rollup merge of #132119 - compiler-errors:effects-old-solver, r=lcnr
workingjubilee Oct 29, 2024
b8f08fe
Rollup merge of #132194 - compiler-errors:rpitit-super-wc, r=spastorino
workingjubilee Oct 29, 2024
a70b90b
Rollup merge of #132216 - klensy:c_uint, r=cuviper
workingjubilee Oct 29, 2024
5ee13ae
Rollup merge of #132233 - WaffleLapkin:box-module-split, r=workingjub…
workingjubilee Oct 29, 2024
423d4f0
Rollup merge of #132266 - krasimirgg:llvm-20-testfix, r=hanna-kruppe,…
workingjubilee Oct 29, 2024
29a7ca9
Rollup merge of #132270 - yakiimoninja:fs-truncate-docs, r=Noratrieb
workingjubilee Oct 29, 2024
3eb7ddd
Rollup merge of #132284 - camelid:rm-ping, r=workingjubilee
workingjubilee Oct 29, 2024
9d58475
Rollup merge of #132293 - Urgau:tests-check-cfg-out-triagebot, r=lqd
workingjubilee Oct 29, 2024
0963636
Rollup merge of #132312 - jieyouxu:delete-crashes-23707, r=matthiaskrgr
workingjubilee Oct 29, 2024
6c5641c
Rollup merge of #132313 - Zalathar:directive-list, r=jieyouxu
workingjubilee Oct 29, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 2 additions & 14 deletions compiler/rustc_hir_analysis/src/collect/item_bounds.rs
Original file line number Diff line number Diff line change
Expand Up @@ -367,20 +367,8 @@ pub(super) fn explicit_item_bounds_with_filter(
// a projection self type.
Some(ty::ImplTraitInTraitData::Trait { opaque_def_id, .. }) => {
let opaque_ty = tcx.hir_node_by_def_id(opaque_def_id.expect_local()).expect_opaque_ty();
let item_ty = Ty::new_projection_from_args(
tcx,
def_id.to_def_id(),
ty::GenericArgs::identity_for_item(tcx, def_id),
);
let bounds = opaque_type_bounds(
tcx,
opaque_def_id.expect_local(),
opaque_ty.bounds,
item_ty,
opaque_ty.span,
filter,
);
assert_only_contains_predicates_from(filter, bounds, item_ty);
let bounds =
associated_type_bounds(tcx, def_id, opaque_ty.bounds, opaque_ty.span, filter);
return ty::EarlyBinder::bind(bounds);
}
Some(ty::ImplTraitInTraitData::Impl { .. }) => span_bug!(
Expand Down
21 changes: 21 additions & 0 deletions tests/ui/associated-type-bounds/implied-from-self-where-clause.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
// Make sure that, like associated type where clauses on traits, we gather item
// bounds for RPITITs from RTN where clauses.

//@ check-pass

#![feature(return_type_notation)]

trait Foo
where
Self::method(..): Send,
{
fn method() -> impl Sized;
}

fn is_send(_: impl Send) {}

fn test<T: Foo>() {
is_send(T::method());
}

fn main() {}