Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

It is since C++20. Comment author tries to make code verbose to make their point or does not know about auto and the state of C++.


I simply copied it from the article (minus the surrounding function).

Fortunately you only need to write this at the utility function, not at every call site, so it's ok.

In general I find various new features in C++ suffer from verbosity, but of course without experimental this one gets better.


auto in function signatures is just really, really stupid.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: