add List.clone

This commit is contained in:
Folkert 2024-01-20 20:27:59 +01:00
parent ebfcd71e8d
commit f1ffc36efe
No known key found for this signature in database
GPG key ID: 1F17F6FFD112B97C
14 changed files with 147 additions and 4 deletions

View file

@ -1611,6 +1611,7 @@ fn low_level_no_rc(lowlevel: &LowLevel) -> RC {
Hash => RC::NoRc,
ListIsUnique => RC::Rc,
ListClone => RC::Rc,
BoxExpr | UnboxExpr => {
unreachable!("These lowlevel operations are turned into mono Expr's")

View file

@ -1366,6 +1366,7 @@ fn lowlevel_borrow_signature(arena: &Bump, op: LowLevel) -> &[Ownership] {
Hash => arena.alloc_slice_copy(&[borrowed, irrelevant]),
ListIsUnique => arena.alloc_slice_copy(&[borrowed]),
ListClone => arena.alloc_slice_copy(&[owned]),
BoxExpr | UnboxExpr => {
unreachable!("These lowlevel operations are turned into mono Expr's")