mirror of
https://github.com/roc-lang/roc.git
synced 2025-10-01 07:41:12 +00:00
make match exhaustive
This commit is contained in:
parent
4e6aac760a
commit
ef89ff15a1
1 changed files with 9 additions and 3 deletions
|
@ -344,12 +344,10 @@ pub fn decrement_refcount_layout<'a, 'ctx, 'env>(
|
|||
)
|
||||
}
|
||||
}
|
||||
PhantomEmptyStruct => {}
|
||||
|
||||
Struct(layouts) => {
|
||||
modify_refcount_struct(env, parent, layout_ids, value, layouts, Mode::Dec);
|
||||
}
|
||||
RecursivePointer => todo!("TODO implement decrement layout of recursive tag union"),
|
||||
|
||||
Union(variant) => {
|
||||
use UnionLayout::*;
|
||||
|
@ -388,6 +386,10 @@ pub fn decrement_refcount_layout<'a, 'ctx, 'env>(
|
|||
}
|
||||
}
|
||||
|
||||
PhantomEmptyStruct => {}
|
||||
|
||||
RecursivePointer => todo!("TODO implement decrement layout of recursive tag union"),
|
||||
|
||||
FunctionPointer(_, _) | Pointer(_) => {}
|
||||
}
|
||||
}
|
||||
|
@ -525,7 +527,11 @@ pub fn increment_refcount_layout<'a, 'ctx, 'env>(
|
|||
modify_refcount_struct(env, parent, layout_ids, value, layouts, Mode::Inc);
|
||||
}
|
||||
|
||||
_ => {}
|
||||
PhantomEmptyStruct => {}
|
||||
|
||||
RecursivePointer => todo!("TODO implement decrement layout of recursive tag union"),
|
||||
|
||||
FunctionPointer(_, _) | Pointer(_) => {}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue