1
Fork 0

Add opt_rpitit_info query

This commit is contained in:
Santiago Pastorino 2023-02-28 18:27:26 -03:00
parent 5423745db8
commit 5295de1694
No known key found for this signature in database
GPG key ID: 8131A24E0C79EFAF
3 changed files with 15 additions and 0 deletions

View file

@ -1144,6 +1144,14 @@ rustc_queries! {
separate_provide_extern
}
/// The `opt_rpitit_info` query returns the pair of the def id of the function where the RPIT
/// is defined and the opaque def id if any.
query opt_rpitit_info(def_id: DefId) -> Option<ty::ImplTraitInTraitData> {
desc { |tcx| "opt_rpitit_info `{}`", tcx.def_path_str(def_id) }
cache_on_disk_if { def_id.is_local() }
feedable
}
/// Gets the span for the definition.
query def_span(def_id: DefId) -> Span {
desc { |tcx| "looking up span for `{}`", tcx.def_path_str(def_id) }