(vm: &VirtualMachine, msg: impl Into<String>)
| 723 | } |
| 724 | |
| 725 | pub fn new_struct_error(vm: &VirtualMachine, msg: impl Into<String>) -> PyBaseExceptionRef { |
| 726 | // can't just STRUCT_ERROR.get().unwrap() cause this could be called before from buffer |
| 727 | // machinery, independent of whether _struct was ever imported |
| 728 | let msg: String = msg.into(); |
| 729 | vm.new_exception_msg(struct_error_type(vm).clone(), msg.into()) |
| 730 | } |
no test coverage detected