impl Default for Runnable structs

This commit is contained in:
Shunsuke Shibayama 2022-11-17 22:05:04 +09:00
parent d8e2ece224
commit 07c62de125
9 changed files with 19 additions and 5 deletions

View file

@ -584,6 +584,12 @@ pub struct PythonVersion {
pub micro: Option<u8>,
}
impl Default for PythonVersion {
fn default() -> Self {
Self::new(3, Some(11), Some(0))
}
}
impl PythonVersion {
pub const fn new(major: u8, minor: Option<u8>, micro: Option<u8>) -> Self {
Self {