summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJonas Toth <jonas.toth@gmail.com>2018-07-23 17:34:25 +0000
committerJonas Toth <jonas.toth@gmail.com>2018-07-23 17:34:25 +0000
commit966b5203bde7dfb01b548c04c99335bc896e2e0f (patch)
tree21043e096e4d852e97f649072efaf943a46a52e3
parentd773cb99f135a6b51e00d866408ddf694ffb42a3 (diff)
downloadbcm5719-llvm-966b5203bde7dfb01b548c04c99335bc896e2e0f.tar.gz
bcm5719-llvm-966b5203bde7dfb01b548c04c99335bc896e2e0f.zip
Revert "[clang-tidy] fix PR36489 - respect deduced pointer types from auto as well"
I applied the wrong patch. llvm-svn: 337712
-rw-r--r--clang-tools-extra/test/clang-tidy/cppcoreguidelines-pro-bounds-pointer-arithmetic.cpp29
1 files changed, 1 insertions, 28 deletions
diff --git a/clang-tools-extra/test/clang-tidy/cppcoreguidelines-pro-bounds-pointer-arithmetic.cpp b/clang-tools-extra/test/clang-tidy/cppcoreguidelines-pro-bounds-pointer-arithmetic.cpp
index 2b7f9233e36..7cbc6ddf96a 100644
--- a/clang-tools-extra/test/clang-tidy/cppcoreguidelines-pro-bounds-pointer-arithmetic.cpp
+++ b/clang-tools-extra/test/clang-tidy/cppcoreguidelines-pro-bounds-pointer-arithmetic.cpp
@@ -85,32 +85,5 @@ void okay() {
auto diff = p - q; // OK, result is arithmetic
- for (int ii : a)
- ; // OK, pointer arithmetic generated by compiler
-}
-
-// Fix PR36207
-namespace std {
-template <typename CharT>
-struct char_traits {};
-
-template <typename T>
-struct allocator {};
-
-template <typename CharT,
- typename Traits = char_traits<CharT>,
- typename Allocator = allocator<CharT>>
-class basic_string {};
-
-template <class CharT, class Traits, class Alloc>
-basic_string<CharT, Traits, Alloc> operator+(const basic_string<CharT, Traits, Alloc> &lhs,
- const CharT *rhs) {}
-
-using string = basic_string<char>;
-} // namespace std
-
-std::string str_generated() {}
-
-void problematic_addition() {
- std::string status = str_generated() + " is not found";
+ for(int ii : a) ; // OK, pointer arithmetic generated by compiler
}
OpenPOWER on IntegriCloud