No thanks, I’ll be staying with
datastruct.nextState()
rather thanconst nextState = prevState.nextState()
You can easily do the first option in Rust, you just use the mut
keyword. That’s it, nothing more than that. And you’ll find that you quite rarely have to do that, and when you do it, it’s actually quite a useful signal to be aware of, since mutability sometimes means a bit more surprising data changes.
At least use TOML if you like ini, there is no ini spec but TOML can look quite similar.