diff options
Diffstat (limited to 'lib/CodeGen/CGExprCXX.cpp')
| -rw-r--r-- | lib/CodeGen/CGExprCXX.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/CodeGen/CGExprCXX.cpp b/lib/CodeGen/CGExprCXX.cpp index 9ce90c0ce8..7177a64e74 100644 --- a/lib/CodeGen/CGExprCXX.cpp +++ b/lib/CodeGen/CGExprCXX.cpp @@ -65,12 +65,12 @@ static bool canDevirtualizeMemberFunctionCalls(ASTContext &Context, // If the member function is marked 'final', we know that it can't be // overridden and can therefore devirtualize it. - if (MD->isMarkedFinal()) + if (MD->hasAttr<FinalAttr>()) return true; // Similarly, if the class itself is marked 'final' it can't be overridden // and we can therefore devirtualize the member function call. - if (MD->getParent()->isMarkedFinal()) + if (MD->getParent()->hasAttr<FinalAttr>()) return true; if (const DeclRefExpr *DRE = dyn_cast<DeclRefExpr>(Base)) { |
