3 ms·
Never give advice without telling why, because it's very likely that people will forget it if they don't understand your advice.
by clishem 10y ago
Never give advice without telling why, because it's very likely that people will forget it if they don't understand your advice.
- thecpphorse 10y agoOk. auto i{42}; // std::initializer_list<int>
- david-given 10y agoBut why is that bad?
- lmitchell 10y agoBecause `i` isn't an int, it's an initializer_list, and you almost never want to actually create an initializer_list instead of an int? Seems pretty understandable to me.
- thecpphorse 10y agoIt's unexpected. Nobody ever* wanted to assign an initializer list to a named variable. [*] pretty much
- hellofunk 10y agoNo longer applies with c++17