https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61379

Jakub Jelinek <jakub at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |jakub at gcc dot gnu.org

--- Comment #3 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
This isn't specific to pure virtual member functions, any virtual member
functions will behave like that.
And I think the behavior is correct, when a member function is virtual, it can
be overridden by some other function, and [[noreturn]] applies solely to
function declarations/definitions, not function types, so the fact that some
virtual member function is marked [[noreturn]] doesn't mean it must be
overridden by [[noreturn]] as well.
__attribute__((noreturn)) can be applied to function types too, but I think we
don't change the type of the virtual member just because a particular virtual
member is __attribute__((noreturn)).

Reply via email to