Skip to content

Commit

Permalink
Avoid half-open range patterns to appease our MSRV build.
Browse files Browse the repository at this point in the history
  • Loading branch information
adamreichold committed Jul 21, 2024
1 parent cc5918f commit 09d1e49
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/npyffi/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ fn get_numpy_api<'py>(

const fn api_version_to_numpy_version_range(api_version: c_uint) -> (&'static str, &'static str) {
match api_version {
..=0x00000008 => ("?", "1.7"),
api_version if api_version <= 0x00000008 => ("?", "1.7"),
0x00000009 => ("1.8", "1.9"),
0x0000000A => ("1.10", "1.12"),
0x0000000B => ("1.13", "1.13"),
Expand All @@ -57,7 +57,7 @@ const fn api_version_to_numpy_version_range(api_version: c_uint) -> (&'static st
0x0000000F => ("1.22", "1.22"),
0x00000010 => ("1.23", "1.24"),
0x00000011 => ("1.25", "1.26"),
0x00000012.. => ("2.0", "?"),
api_version if api_version >= 0x00000012 => ("2.0", "?"),
}
}

Expand Down

0 comments on commit 09d1e49

Please sign in to comment.