about summary refs log tree commit diff
path: root/compiler/rustc_data_structures/src/graph/reference.rs
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2024-04-02 05:17:28 +0000
committerbors <bors@rust-lang.org>2024-04-02 05:17:28 +0000
commite2cf2cb30388385f0fe6b406a31a3f9841a72a62 (patch)
treeaab0bcc516128fd2357ce0e143e585b75d98cd2b /compiler/rustc_data_structures/src/graph/reference.rs
parent6bbd8c519af69ebc30486d6cf02b7f7a52113950 (diff)
parent09ea3f93ee6497247172a80ba17493748d08b64c (diff)
downloadrust-e2cf2cb30388385f0fe6b406a31a3f9841a72a62.tar.gz
rust-e2cf2cb30388385f0fe6b406a31a3f9841a72a62.zip
Auto merge of #122267 - compiler-errors:closure-like-goals, r=lcnr
Eagerly instantiate closure/coroutine-like bounds with placeholders to deal with binders correctly

A follow-up to #119849, however it aims to fix a different set of issues. Currently, we have trouble confirming goals where built-in closure/fnptr/coroutine signatures are compared against higher-ranked goals.

Currently, we don't support goals like `for<'a> fn(&'a ()): Fn(&'a ())` because we don't expect the self type of goal to reference any bound regions from the goal, because we don't really know how to deal with the double binder of predicate + self type. However, this definitely can be reached (#121653) -- and in fact, it results in post-mono errors in the case of #112347 where the builtin type (e.g. a coroutine) is hidden behind a TAIT.

The proper fix here is to instantiate the goal before trying to extract the signature from the self type. See final two commits.

r? lcnr
Diffstat (limited to 'compiler/rustc_data_structures/src/graph/reference.rs')
0 files changed, 0 insertions, 0 deletions