Why deference MaybeUninit().unint().as_mut_ptr() is safe?

This is not a nice way present your idea.

As for doing better, there are a large number of instances where the choice between something being UB or not UB is more a natural outcome of the language design or its underlying implementation, rather than a question of doing better.

As the tradeoffs in software engineering change over time, so does the ideal solution. Some 40 years ago when the first C standards were written down, by people no less competent than those that work on Rust today, the design of the language and the list of behaviours not defined likely made much more sense in context of back then than they do right now. It is not all that unlikely that some years down the line the choices made by Rust won't make all that much of sense as they do today, too.