3 ms·
Try auto foo = some_big_type(); If you're not talking about initialization, but instead talking about construction, just do some_big_type foo; (no parens neede
by mpyne 14y ago
Try auto foo = some_big_type();
If you're not talking about initialization, but instead talking about construction, just do some_big_type foo; (no parens needed).
- btilly 14y agoIf you're not talking about initialization... I thought I was very clear when I said: "I want this thing, and I want it to get the obvious default initialization?" I often wound up typing something like this: std::vector< my_big_type > list_foo = std::vector< my_big_type >(); It seemed useless the first time, and just got sillier as time went on.