> Yes, all except this one (I think): > > error: 'error' diagnostics expected but not seen: > File D:\src\llvm\tools\clang\test\SemaCXX\virtual-override.cpp Line > 288: 'static' member function 'foo' overrides a virtual function > error: 'error' diagnostics seen but not expected: > File D:\src\llvm\tools\clang\test\SemaCXX\virtual-override.cpp Line > 288: virtual function 'foo' has different calling convention > attributes ('void ()') than the function it overrides (which has > calling convention 'void () __attribute__((thiscall))') > 2 errors generated. > > I guess this is also a QOI problem, but the diagnostic here gets > pretty misleading.Yes, I guess this a case of the error being pedantically correct. We should suppress the second error. Cheers, Rafael
On Tue, Dec 10, 2013 at 3:01 PM, Rafael Espíndola <rafael.espindola at gmail.com> wrote:>> Yes, all except this one (I think): >> >> error: 'error' diagnostics expected but not seen: >> File D:\src\llvm\tools\clang\test\SemaCXX\virtual-override.cpp Line >> 288: 'static' member function 'foo' overrides a virtual function >> error: 'error' diagnostics seen but not expected: >> File D:\src\llvm\tools\clang\test\SemaCXX\virtual-override.cpp Line >> 288: virtual function 'foo' has different calling convention >> attributes ('void ()') than the function it overrides (which has >> calling convention 'void () __attribute__((thiscall))') >> 2 errors generated. >> >> I guess this is also a QOI problem, but the diagnostic here gets >> pretty misleading. > > Yes, I guess this a case of the error being pedantically correct. We > should suppress the second error.Something like http://llvm-reviews.chandlerc.com/D2375 ? - Hans
> Something like http://llvm-reviews.chandlerc.com/D2375 ?Seems reasonable, but could the check in CheckFunctionDeclaration be merged with this one so that we don't get duplicated code handling diag::err_static_overrides_virtual? Cheers, Rafael