commit | 8195bc932d27e21be46b9a1f8ce268ebd419246b | [log] [tgz] |
---|---|---|
author | Anders Carlsson <andersca@mac.com> | Sun Sep 13 21:01:57 2009 +0000 |
committer | Anders Carlsson <andersca@mac.com> | Sun Sep 13 21:01:57 2009 +0000 |
tree | 3bd6deedd5b72e169b73ee20e59f309c087cb3d3 | |
parent | e0c8822eec9d3b2afa62c5e6168a8a8f52aeb2c4 [diff] [blame] |
CXXMethodDecl::isVirtual needs to check the canonical declaration. Fixes PR4878. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81715 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/test/SemaCXX/attr-deprecated.cpp b/test/SemaCXX/attr-deprecated.cpp index c1bdfcc..54f8b5b 100644 --- a/test/SemaCXX/attr-deprecated.cpp +++ b/test/SemaCXX/attr-deprecated.cpp
@@ -54,3 +54,13 @@ c->C::f(); c->B::f(); // expected-warning{{'f' is deprecated}} } + +struct D { + virtual void f() __attribute__((deprecated)); +}; + +void D::f() { } + +void f(D* d) { + d->f(); +}