PR c++/65974
* decl2.c (mark_vtable_entries): Suppress -Wdeprecated.
From-SVN: r226908
+2015-08-14 Jason Merrill <jason@redhat.com>
+
+ PR c++/65974
+ * decl2.c (mark_vtable_entries): Suppress -Wdeprecated.
+
2015-08-12 Jason Merrill <jason@redhat.com>
PR c++/67104
tree fnaddr;
unsigned HOST_WIDE_INT idx;
+ /* It's OK for the vtable to refer to deprecated virtual functions. */
+ warning_sentinel w(warn_deprecated_decl);
+
FOR_EACH_CONSTRUCTOR_VALUE (CONSTRUCTOR_ELTS (DECL_INITIAL (decl)),
idx, fnaddr)
{
--- /dev/null
+// PR c++/65974
+// { dg-options "-Wdeprecated" }
+
+struct S {
+ void bar();
+
+ __attribute__((deprecated("use bar() instead.")))
+ virtual void foo();
+};
+
+void S::foo() { bar(); }
+
+int main()
+{
+ return 0;
+}