mirror of
https://github.com/rust-lang/rust.git
synced 2024-12-24 14:34:23 +00:00
generic smir stable impl for Binder
This commit is contained in:
parent
8771282d4e
commit
c2158a44e1
@ -525,13 +525,17 @@ impl<'tcx> Stable<'tcx> for ty::GenericArgs<'tcx> {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
impl<'tcx> Stable<'tcx> for ty::PolyFnSig<'tcx> {
|
impl<'tcx, S, V> Stable<'tcx> for ty::Binder<'tcx, S>
|
||||||
type T = stable_mir::ty::PolyFnSig;
|
where
|
||||||
|
S: Stable<'tcx, T = V>,
|
||||||
|
{
|
||||||
|
type T = stable_mir::ty::Binder<V>;
|
||||||
|
|
||||||
fn stable(&self, tables: &mut Tables<'tcx>) -> Self::T {
|
fn stable(&self, tables: &mut Tables<'tcx>) -> Self::T {
|
||||||
use stable_mir::ty::Binder;
|
use stable_mir::ty::Binder;
|
||||||
|
|
||||||
Binder {
|
Binder {
|
||||||
value: self.skip_binder().stable(tables),
|
value: self.as_ref().skip_binder().stable(tables),
|
||||||
bound_vars: self
|
bound_vars: self
|
||||||
.bound_vars()
|
.bound_vars()
|
||||||
.iter()
|
.iter()
|
||||||
|
Loading…
Reference in New Issue
Block a user