Since rvalue references were not supported before C++11, there were no move constructors. The const T&
arguments makes it use the copy constructor even for temporaries, which is the same as calling the copy constructor via a by-value argument? std::vector
's void push_back(const T& Val)
allows Val
to receive the right value, so why not pass it by value?
The other question is: Why can const T&
receive right values?