commit | 198b0f81d0ac86849078b83345bb1bc623e69291 | [log] [tgz] |
---|---|---|
author | George Liu <liuxiwei@inspur.com> | Thu Aug 04 20:22:48 2022 +0800 |
committer | George Liu <liuxiwei@inspur.com> | Fri Aug 05 00:24:27 2022 +0000 |
tree | bf1296767249487a16215e6397b3153bb3f0d3c3 | |
parent | be1470cc12179d10e7235fc19e934d47a76716a6 [diff] |
Safe overloading with std::equal Since C++20, there is a safer way to overload std::equal: template< class InputIt1, class InputIt2 > constexpr bool equal( InputIt1 first1, InputIt1 last1, InputIt2 first2, InputIt2 last2 ); Because if they are different lengths, it won't run past on either side. In theory, they should always be the same length. Signed-off-by: George Liu <liuxiwei@inspur.com> Change-Id: I1d25331521c1590b5f448f93b657f58f9f06d778