forked from OSchip/llvm-project
parent
57cc65ff47
commit
54904aba47
|
@ -6242,7 +6242,6 @@ void Sema::CheckCompletedCXXClass(CXXRecordDecl *Record) {
|
|||
if (const FinalAttr *FA = dtor->getAttr<FinalAttr>()) {
|
||||
Diag(FA->getLocation(), diag::warn_final_dtor_non_final_class)
|
||||
<< FA->isSpelledAsSealed()
|
||||
<< FixItHint::CreateRemoval(FA->getLocation())
|
||||
<< FixItHint::CreateInsertion(
|
||||
getLocForEndOfToken(Record->getLocation()),
|
||||
(FA->isSpelledAsSealed() ? " sealed" : " final"));
|
||||
|
|
|
@ -8,7 +8,6 @@ class A {
|
|||
class B { // expected-note {{mark 'B' as 'final' to silence this warning}}
|
||||
// CHECK: fix-it:"{{.*}}":{[[@LINE-1]]:8-[[@LINE-1]]:8}:" final"
|
||||
virtual ~B() final; // expected-warning {{class with destructor marked 'final' cannot be inherited from}}
|
||||
// CHECK: fix-it:"{{.*}}":{[[@LINE-1]]:18-[[@LINE-1]]:23}:""
|
||||
};
|
||||
|
||||
class C final {
|
||||
|
|
Loading…
Reference in New Issue