throw resource error if OpenOptions raises an error of uncategorized kind (#1375)

This commit is contained in:
Mark
2023-09-21 14:36:53 -06:00
parent 81edd4592f
commit b3239abea1
3 changed files with 26 additions and 11 deletions

View File

@@ -4244,7 +4244,7 @@ impl Machine {
Ok(Number::Integer(n)) => match (&*n).try_into() as Result<usize, _> {
Ok(n) => n,
Err(_) => {
let err = self.machine_st.resource_error(len);
let err = self.machine_st.resource_error(ResourceError::FiniteMemory(len));
return Err(self.machine_st.error_form(err, stub_gen()));
}
},