https://codereview.chromium.org/851243002/diff/1/testing/gtest-support.h
File testing/gtest-support.h (right):
https://codereview.chromium.org/851243002/diff/1/testing/gtest-support.h#newcode38
testing/gtest-support.h:38: for (_type const _var : _container)
\
I know that this is the literal translation (more exact: generalization)
of the previous code, but 2 comments:
* Why should we still pass the type? We could use "auto".
* I think that the type is always primitive, but nevertheless the
recommended and future-proof way would be using a const ref.
In a nutshell: Why not simply "for (const auto& _var: container)"?
https://codereview.chromium.org/851243002/
--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
---
You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.