diff options
| author | Celina G. Val <celinval@amazon.com> | 2023-10-19 17:06:53 -0700 |
|---|---|---|
| committer | Celina G. Val <celinval@amazon.com> | 2023-10-19 17:12:26 -0700 |
| commit | 6ed2a76bcc2a963c28080d6ee3ad928ec9367a03 (patch) | |
| tree | 8bb460c975fdab978c539884f4388b14b9b2e8ed /compiler/stable_mir/src/ty.rs | |
| parent | cc705b801236d064260bb67b3a0a25e4747fa7ec (diff) | |
| download | rust-6ed2a76bcc2a963c28080d6ee3ad928ec9367a03.tar.gz rust-6ed2a76bcc2a963c28080d6ee3ad928ec9367a03.zip | |
Add stable Instance::body() and RustcInternal trait
The `Instance::body()` returns a monomorphized body. For that, we had to implement visitor that monomorphize types and constants. We are also introducing the RustcInternal trait that will allow us to convert back from Stable to Internal. Note that this trait is not yet visible for our users as it depends on Tables. We should probably add a new trait that can be exposed.
Diffstat (limited to 'compiler/stable_mir/src/ty.rs')
| -rw-r--r-- | compiler/stable_mir/src/ty.rs | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/compiler/stable_mir/src/ty.rs b/compiler/stable_mir/src/ty.rs index 003045a4696..440c9a1f031 100644 --- a/compiler/stable_mir/src/ty.rs +++ b/compiler/stable_mir/src/ty.rs @@ -225,6 +225,8 @@ pub struct ImplDef(pub DefId); #[derive(Clone, PartialEq, Eq, Debug)] pub struct RegionDef(pub DefId); +/// A list of generic arguments. +/// The second field is for internal usage to allow retrieving the internal representation. #[derive(Clone, Debug)] pub struct GenericArgs(pub Vec<GenericArgKind>); |
