From d0ea036e8316aebe77986c060a899ee6c0510ed2 Mon Sep 17 00:00:00 2001 From: Aiden Fox Ivey Date: Tue, 2 Sep 2025 17:27:28 -0400 Subject: ZJIT: Use .is_some_and --- zjit/src/options.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/zjit/src/options.rs b/zjit/src/options.rs index 1d5509d89c..f0a7f0bc7b 100644 --- a/zjit/src/options.rs +++ b/zjit/src/options.rs @@ -336,7 +336,7 @@ pub extern "C" fn rb_zjit_option_enabled_p(_ec: EcPtr, _self: VALUE) -> VALUE { #[unsafe(no_mangle)] pub extern "C" fn rb_zjit_stats_enabled_p(_ec: EcPtr, _self: VALUE) -> VALUE { // Builtin zjit.rb calls this even if ZJIT is disabled, so OPTIONS may not be set. - if unsafe { OPTIONS.as_ref() }.map_or(false, |opts| opts.stats) { + if unsafe { OPTIONS.as_ref() }.is_some_and(|opts| opts.stats) { Qtrue } else { Qfalse -- cgit v1.2.3