I need to initialise a VecDeque
in a const context, but VecDeque::new
is not const
. However, Vec::new
is const
. Vec
and VecDeque
are quite similar under the hood; is there anything stopping VecDeque
from having a const initialiser?
If it is possible, how would I go about adding a PR to Rust, would I need to discuss it with someone prior? I've noticed other const
functions have a rustc_const_stable
attribute suggesting it's not as trivial as just adding the const
keyword.