flush_io Flush stdout and stderr. Errors are silently ignored.
(&self)
| 1232 | /// |
| 1233 | /// Flush stdout and stderr. Errors are silently ignored. |
| 1234 | fn flush_io(&self) { |
| 1235 | if let Ok(stdout) = self.sys_module.get_attr("stdout", self) { |
| 1236 | let _ = self.call_method(&stdout, identifier!(self, flush).as_str(), ()); |
| 1237 | } |
| 1238 | if let Ok(stderr) = self.sys_module.get_attr("stderr", self) { |
| 1239 | let _ = self.call_method(&stderr, identifier!(self, flush).as_str(), ()); |
| 1240 | } |
| 1241 | } |
| 1242 | |
| 1243 | /// Clear module references during shutdown. |
| 1244 | /// Follows the same phased algorithm as pylifecycle.c finalize_modules(): |
no test coverage detected