ADT: Remove references in has_rbegin for reverse()
authorDuncan P. N. Exon Smith <dexonsmith@apple.com>
Thu, 18 Aug 2016 16:22:54 +0000 (16:22 +0000)
committerDuncan P. N. Exon Smith <dexonsmith@apple.com>
Thu, 18 Aug 2016 16:22:54 +0000 (16:22 +0000)
commitb28eb332d9ea8b0fdfdce49909c4ea9e4b57a35f
tree69faf7a0ada12daf6992bafb05d29d2086dd99c6
parent615b820af6338c0cd95acd3ff686c9f7901f109d
ADT: Remove references in has_rbegin for reverse()

As a follow-up to r278991, add some tests that check that
decltype(reverse(R).begin()) == decltype(R.rbegin()), and get them
passing by adding std::remove_reference to has_rbegin.

I'm using static_assert instead of EXPECT_TRUE (and updated the other
has_rbegin check from r278991 in the same way) since I figure that's
more helpful.

llvm-svn: 279084
llvm/include/llvm/ADT/STLExtras.h
llvm/unittests/ADT/RangeAdapterTest.cpp