Fix error type in itertools.count constructor

This commit is contained in:
Padraic Fanning
2022-07-01 20:45:51 -04:00
parent 3bc65bd504
commit 71968b316a

View File

@@ -197,7 +197,7 @@ mod decl {
let start = start.into_option().unwrap_or_else(|| vm.new_pyobj(0));
let step = step.into_option().unwrap_or_else(|| vm.new_pyobj(1));
if !PyNumber::check(&start, vm) || !PyNumber::check(&step, vm) {
return Err(vm.new_value_error("a number is require".to_owned()));
return Err(vm.new_type_error("a number is required".to_owned()));
}
PyItertoolsCount {