]> granicus.if.org Git - clang/commit
[AST] Use llvm::TrailingObjects in CXXTryStmt
authorBenjamin Kramer <benny.kra@googlemail.com>
Mon, 23 Jul 2018 12:45:24 +0000 (12:45 +0000)
committerBenjamin Kramer <benny.kra@googlemail.com>
Mon, 23 Jul 2018 12:45:24 +0000 (12:45 +0000)
commite08d24e89fbaf9178e70e9ffcec8ecdfedd2b2fb
tree33262f7dbe12c916d48d081298a4d06a9e4f9193
parent2e2d5d03cb9ce174c39c2975c6d9d510058e8421
[AST] Use llvm::TrailingObjects in CXXTryStmt

1. Use llvm::TrailingObjects in CXXTryStmt instead of manually doing the reinterpret_casts + pointer arithmetic. This is more consistent with other classes using this idiom and this make it clearer that this class has trailing objects.
2. Make the class CXXTryStmt final since it has trailing objects.
3. Move the friend declarations together.

No functional changes.

Patch by Bruno Ricci!

Differential Revision: https://reviews.llvm.org/D48873

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@337688 91177308-0d34-0410-b5e6-96231b3b80d8
include/clang/AST/StmtCXX.h
lib/AST/StmtCXX.cpp