Collect into Result rather than unwrap
Copyright (c) 2021, Arm Limited
This commit is contained in:
@@ -685,8 +685,8 @@ where
|
||||
} else {
|
||||
let lanes = extractlanes(&arg(0)?, ctrl_ty.lane_type())?
|
||||
.into_iter()
|
||||
.map(|lane| lane.count_ones().unwrap())
|
||||
.collect::<SimdVec<V>>();
|
||||
.map(|lane| lane.count_ones())
|
||||
.collect::<ValueResult<SimdVec<V>>>()?;
|
||||
vectorizelanes(&lanes, ctrl_ty)?
|
||||
};
|
||||
assign(count)
|
||||
|
||||
Reference in New Issue
Block a user