takuto.ikuta added inline comments.
================
Comment at: clang/lib/Sema/SemaDecl.cpp:12624
+ isa<CXXMethodDecl>(D)) {
+ CXXMethodDecl *MD = dyn_cast<CXXMethodDecl>(D);
+ CXXRecordDecl *Class = MD->getParent();
----------------
hans wrote:
> Hmm, now we're adding an AST walk over all inline methods which probably
> slows us down a bit. Not sure I have any better ideas though.
>
> In any case, ActOnFinishInlineFunctionDef needs a comment explaining why it's
> doing this.
Added comment. I think typical code does not have static variables in inline
function and this check is worth to be done for the performance improvement.
https://reviews.llvm.org/D51340
_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits