CarlosAlbertoEnciso added inline comments.
================ Comment at: lib/Sema/SemaDecl.cpp:12598 + // have to apply optnone due to a pragma. + AddRangeBasedOptnone(FD); + ---------------- erichkeane wrote: > Should thi sonly happen if this is a definition? Additionally, does this > negate the need for the other call to this in ActOnFunctionDeclarator? First of all, thanks for your review. Based on your comments, I found couple of issues with my patch: For a normal function, the setting of the 'optnone' attribute was done twice: ActOnFunctionDeclarator and ActOnFinishFunctionBody. The setting of the 'optnone' attribute is not consistent for both lambda and normal functions. For normal functions being done at the start of the definition and for lambdas at the end of the function body. Based on the previous findings, now I am setting the 'optnone' attribute in ActOnStartOfLambdaDefinition. I will update the patch to reflect the changes. Repository: rC Clang https://reviews.llvm.org/D43821 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits