added typetree support for memcpy

This commit is contained in:
Karan Janthe
2025-08-23 23:10:48 +00:00
parent 5d3ebc3804
commit 664e83b3e7
21 changed files with 135 additions and 34 deletions

View File

@@ -2280,12 +2280,12 @@ pub fn typetree_from_ty<'tcx>(tcx: TyCtxt<'tcx>, ty: Ty<'tcx>) -> TypeTree {
let child = typetree_from_ty(tcx, inner_ty);
return TypeTree(vec![Type {
offset: -1,
size: 8, // TODO(KMJ-007): Get actual pointer size from target
size: tcx.data_layout.pointer_size().bytes_usize(),
kind: Kind::Pointer,
child,
}]);
}
// TODO(KMJ-007): Handle arrays, slices, structs, and other complex types
// FIXME(KMJ-007): Handle arrays, slices, structs, and other complex types
TypeTree::new()
}