mirror of
https://github.com/roc-lang/roc.git
synced 2025-09-30 15:21:12 +00:00
debug_assert with matches!
This commit is contained in:
parent
65e5a3929d
commit
11daeb4374
1 changed files with 8 additions and 5 deletions
|
@ -446,11 +446,14 @@ where
|
|||
args.len(),
|
||||
"NumToFloat: expected to have exactly one argument"
|
||||
);
|
||||
// debug_assert_eq!(
|
||||
// Layout::Builtin(Builtin::Float(FloatWidth::F32 | FloatWidth::F64)),
|
||||
// *ret_layout,
|
||||
// "NumToFloat: expected to have return layout of type Float64"
|
||||
// );
|
||||
|
||||
debug_assert!(
|
||||
matches!(
|
||||
*ret_layout,
|
||||
Layout::Builtin(Builtin::Float(FloatWidth::F32 | FloatWidth::F64)),
|
||||
),
|
||||
"NumToFloat: expected to have return layout of type Float"
|
||||
);
|
||||
self.build_num_to_float(sym, &args[0], &arg_layouts[0], ret_layout)
|
||||
}
|
||||
LowLevel::NumRound => self.build_fn_call(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue