Here's what Stroustrup has said on the subject:
Uniform and universal was not designed to be just a 4th alternative. It was designed to be the initialization syntax,and was unfortunately [not] feasible to use with all legacy code, especially
vector
. Had I designedvector
today, you would have had to say something likevector<int> {Count{9}};
to get a count.
And in response to the question "Is the problem vector or {}-init syntax?"
It's the vector design: Had I designed
vector
today, you would have had to say something likevector<int> {Count{9}};
to get a count.The more general problem is to have several semantically different arguments of the same type eventually leads to confusion, especially if they can appear adjectly. For example:
vector<int> v(7,2); // 7 (a count) element with the value 2