You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
uninitialized is hard to use correctly. I haven't removed it yet because I think I have managed to put it on sound ground - it is technically possible to use it correctly. See issue #804 and issue #876 (we have just completed removing all internal usage of this method).
Unfortunately ArrayBase::uninitialized:
Has some usage by actual users - it's a basically popular and easy to use (github code search confirms)
This usage is from casual inspection almost always technically incorrect
The conclusion is that deprecation will have impact on users, but we need to do it, and need to make maybe_uninit easy to use.
Our uninitialized was added before stronger rules crystallized. It had been said (earlier) that let x = std::mem::uninitialized(); *(&mut x) = 1.0; would probably be correct when the type was copy - however that as also been judged as incorrect now eventually (creating a reference to uninit), so there are not many easy ways to use it left - short of using the raw views (partly why they were introduced). Yes, your code breaks this rule (as did ours before the next version - and a few versions back, Rust std was also sometimes breaking this rule).
It now has a replacement. See previous issue #685
If 0.14.0 comes quickly after 0.13.1, probably start with just deprecating the method