Disallow implicit comparisons between different numeric types.

This commit is contained in:
Stephen Chung
2021-02-24 15:45:29 +08:00
parent 0d933d865a
commit 4ac05aee8b
11 changed files with 125 additions and 114 deletions

View File

@@ -647,11 +647,9 @@ mod array_functions {
return Ok(true.into());
}
let def_value = Some(false.into());
for (a1, a2) in array.iter_mut().zip(array2.iter_mut()) {
let equals = ctx
.call_fn_dynamic_raw(OP_EQUALS, true, false, &mut [a1, a2], def_value.as_ref())
.call_fn_dynamic_raw(OP_EQUALS, true, false, &mut [a1, a2])
.map(|v| v.as_bool().unwrap_or(false))?;
if !equals {