Emit Ref wire types for lending rows and splice lend/clone_out adapters in the type checker

This commit is contained in:
Dennis Kobert
2026-08-03 16:33:27 +00:00
parent 562e6602eb
commit 9b45af854a
5 changed files with 723 additions and 39 deletions

View File

@@ -88,8 +88,12 @@ pub fn edge_type<T: 'static>() -> Type {
Type::Fn(Box::new(concrete!(Context)), Box::new(concrete!(T)))
}
pub fn ref_type<T: 'static>() -> Type {
Type::Ref(Box::new(concrete!(T)))
}
pub fn lend_edge_type<T: 'static>() -> Type {
Type::Fn(Box::new(concrete!(Context)), Box::new(Type::Ref(Box::new(concrete!(T)))))
Type::Fn(Box::new(concrete!(Context)), Box::new(ref_type::<T>()))
}
pub fn cache_key<C: CacheHash + ?Sized>(ctx: &C) -> u64 {