From 09d1e4985088b62cf2b94e6194b527d6d71f4841 Mon Sep 17 00:00:00 2001 From: Adam Reichold Date: Sun, 21 Jul 2024 14:33:04 +0200 Subject: [PATCH] Avoid half-open range patterns to appease our MSRV build. --- src/npyffi/mod.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/npyffi/mod.rs b/src/npyffi/mod.rs index cb23c0eba..b945b4cc3 100644 --- a/src/npyffi/mod.rs +++ b/src/npyffi/mod.rs @@ -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"), @@ -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", "?"), } }