Files
rust/compiler/rustc_public_bridge
Jonathan Brouwer c6e564426d Rollup merge of #157993 - erickt:rustc-public, r=makai410
Expose more info about ADTs and functions in rustc_public

This allows users of `rustc_public` to do more complex navigation through data structures by exposing the following info:

* `AdtDef::generics_of` - Get the generics for the ADT.
* `AdtDef::inherent_impls` - Get all the impls for the ADT.
* `FnDef::associated_item` - Get the trait or impl block that contains the function if it exists.
* `FnDef::generics_of` - get the generics for a given function.
* `ImplDef::generics_of` - Get the generics for the impl block.
* `ImplDef` implements `CrateDefType` - figure out the type of the impl block with `CrateDefType::ty()` or get the normalized type with `CrateDefType::ty_with_args()`.

This was partially written with the help of Gemini, but I reviewed the code it generated.
2026-07-13 20:18:04 +02:00
..