diff options
author | Ted Kremenek <kremenek@apple.com> | 2010-05-13 06:58:45 +0000 |
---|---|---|
committer | Ted Kremenek <kremenek@apple.com> | 2010-05-13 06:58:45 +0000 |
commit | 01b0cfaf653eead65aa1eeab3dcb4f2500c91385 (patch) | |
tree | 8c7b243e1aa3427f1351ffc852fce67aa1b4f12f | |
parent | b47467ba5d6525e3f50fca6e126f0fa716cd8feb (diff) |
Add test case for <rdar://problem/7880658>.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@103701 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r-- | test/SemaCXX/warn-missing-noreturn.cpp | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/test/SemaCXX/warn-missing-noreturn.cpp b/test/SemaCXX/warn-missing-noreturn.cpp index 8016c3da5c..f2f9b2e2b7 100644 --- a/test/SemaCXX/warn-missing-noreturn.cpp +++ b/test/SemaCXX/warn-missing-noreturn.cpp @@ -36,3 +36,17 @@ namespace test1 { while (condition()) {} } } + + +// <rdar://problem/7880658> - This test case previously had a false "missing return" +// warning. +struct R7880658 { + R7880658 &operator++(); + bool operator==(const R7880658 &) const; + bool operator!=(const R7880658 &) const; +}; + +void f_R7880658(R7880658 f, R7880658 l) { // no-warning + for (; f != l; ++f) { + } +} |