(&self, vm: &VirtualMachine)
| 908 | } |
| 909 | |
| 910 | fn check_valid(&self, vm: &VirtualMachine) -> PyResult<PyMutexGuard<'_, Option<MmapObj>>> { |
| 911 | let m = self.mmap.lock(); |
| 912 | |
| 913 | if m.is_none() { |
| 914 | return Err(vm.new_value_error("mmap closed or invalid")); |
| 915 | } |
| 916 | |
| 917 | Ok(m) |
| 918 | } |
| 919 | |
| 920 | /// TODO: impl resize |
| 921 | #[allow(dead_code)] |
no test coverage detected