diff options
Diffstat (limited to 'clang/lib')
-rw-r--r-- | clang/lib/Sema/SemaDecl.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/clang/lib/Sema/SemaDecl.cpp b/clang/lib/Sema/SemaDecl.cpp index c778ca6c292..d8b6f45e37a 100644 --- a/clang/lib/Sema/SemaDecl.cpp +++ b/clang/lib/Sema/SemaDecl.cpp @@ -2067,6 +2067,13 @@ Sema::ActOnFunctionDeclarator(Scope* S, Declarator& D, DeclContext* DC, } // This is a C++ method declaration. + + // FIXME: All inline method declarations are semantically inline. We + // should add a new bit to keep track of whether they were declared with an + // inline keyword as well. + if (CurContext == DC && IsFunctionDefinition) + isInline = true; + NewFD = CXXMethodDecl::Create(Context, cast<CXXRecordDecl>(DC), D.getIdentifierLoc(), Name, R, (SC == FunctionDecl::Static), isInline); |