Skip to content

Commit 52bba0e

Browse files
jqnatividadclaude
andcommitted
fix: make mimalloc cfg guards in util.rs mutually exclusive
Align the two remaining #[cfg(feature = "mimalloc")] guards in util.rs with the not() pattern used everywhere else in the codebase. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent b17b282 commit 52bba0e

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/util.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -591,7 +591,7 @@ pub fn version() -> String {
591591
.map_or("Unknown", |cpu| cpu.brand().trim());
592592
let physical_cpu_count = System::physical_core_count().unwrap_or(0);
593593

594-
#[cfg(feature = "mimalloc")]
594+
#[cfg(all(feature = "mimalloc", not(feature = "jemallocator")))]
595595
let malloc_kind = {
596596
let mimalloc_version = mimalloc::MiMalloc.version();
597597
format!("mimalloc {mimalloc_version}")
@@ -650,7 +650,7 @@ pub fn show_env_vars() {
650650
for (n, v) in env::vars_os() {
651651
// safety: we know that the env::vars_os() will not fail
652652
let env_var = n.into_string().unwrap();
653-
#[cfg(feature = "mimalloc")]
653+
#[cfg(all(feature = "mimalloc", not(feature = "jemallocator")))]
654654
if env_var.starts_with("QSV_")
655655
|| env_var.starts_with("MIMALLOC_")
656656
|| OTHER_ENV_VARS.contains(&env_var.to_ascii_lowercase().as_str())

0 commit comments

Comments
 (0)