Commit 71530982 by CJ Johnson

Merge pull request #3429 from 1KoT1:master

PiperOrigin-RevId: 379625931
parents 22a2e019 5ef9f63a
......@@ -3981,26 +3981,26 @@ ElementsAreArray(Iter first, Iter last) {
}
template <typename T>
inline internal::ElementsAreArrayMatcher<T> ElementsAreArray(
const T* pointer, size_t count) {
inline auto ElementsAreArray(const T* pointer, size_t count)
-> decltype(ElementsAreArray(pointer, pointer + count)) {
return ElementsAreArray(pointer, pointer + count);
}
template <typename T, size_t N>
inline internal::ElementsAreArrayMatcher<T> ElementsAreArray(
const T (&array)[N]) {
inline auto ElementsAreArray(const T (&array)[N])
-> decltype(ElementsAreArray(array, N)) {
return ElementsAreArray(array, N);
}
template <typename Container>
inline internal::ElementsAreArrayMatcher<typename Container::value_type>
ElementsAreArray(const Container& container) {
inline auto ElementsAreArray(const Container& container)
-> decltype(ElementsAreArray(container.begin(), container.end())) {
return ElementsAreArray(container.begin(), container.end());
}
template <typename T>
inline internal::ElementsAreArrayMatcher<T>
ElementsAreArray(::std::initializer_list<T> xs) {
inline auto ElementsAreArray(::std::initializer_list<T> xs)
-> decltype(ElementsAreArray(xs.begin(), xs.end())) {
return ElementsAreArray(xs.begin(), xs.end());
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment