OP you keep comparing to doesn't even declare the variable. I'm done with you.
Re:Thoughts on Go vs. Rust vs. Zig
by umanwizard on Sunday December 07, 2025 @12:31PM
(#46183395)
OP here, not showing how to declare the variable was an oversight on my part.
static mut COUNTER: u32 = 0;
(at top-level)If on 2024 edition, you will additionally need
#![allow(static_mut_refs)]
And declaring a static variable inside a function, even if in main, smells.