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

--- Comment #7 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
(In reply to Andrew Pinski from comment #6)
> Reduced testcase for that:
> void f(void);
> void f(void) throw(int);
> void f(void) throw(int);
> 
> Noexcept has the same issue:
> void g(void);
> void g(void) noexcept;
> void g(void) noexcept;

It is even worse when the first declaration is in a system header file, the
second declaration does not cause an error during merging but then we lose the
throw/noexcept but have the line number of the second decl so when we go and
merge in the third decl, we do the error message that way.

Reply via email to