News for hackers. Stuff that matters.
Re:How well do you know C++ auto type deduction? by Leherenn on Monday December 15, 2025 @07:03AM (#46273394)
Right, although I would argue the most interesting part of the type here is the container, not the containee.

With good naming it should be pretty obvious it's a Foo, and then either you know the type by heart, or will need to look up the definition anyway.

With standard containers, you can have the assumption that everyone knows the type, at least high level. So knowing whether it's a list, a vector, a stack, a map or a multimap, ... is pretty useful and avoid a lookup.

There are no comments on this comment yet.