From: Paolo Carlini Date: Fri, 2 Mar 2018 18:06:44 +0000 (+0000) Subject: re PR middle-end/81812 (Empty virtual function fails to compile) X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=c660f88b1651c331273d636df9fd4eb191dfd46f;p=gcc.git re PR middle-end/81812 (Empty virtual function fails to compile) 2018-03-02 Paolo Carlini PR c++/81812 * g++.dg/torture/pr81812.C: New. From-SVN: r258150 --- diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 670d388b884..59631e92a9c 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,8 @@ +2018-03-02 Paolo Carlini + + PR c++/81812 + * g++.dg/torture/pr81812.C: New. + 2018-03-02 Marek Polacek PR c++/84171 diff --git a/gcc/testsuite/g++.dg/torture/pr81812.C b/gcc/testsuite/g++.dg/torture/pr81812.C new file mode 100644 index 00000000000..d235e237588 --- /dev/null +++ b/gcc/testsuite/g++.dg/torture/pr81812.C @@ -0,0 +1,16 @@ +struct Error { + virtual void error(... ) const; +}; + +struct ChildNode : virtual Error { + void error(... ) const; +}; + +void ext(const char*, ...); + +void ChildNode::error(...) const +{ +#ifdef FIX + ext(""); +#endif +}