[clang] [CIR] Upstream Exception CXXTryStmt (PR #162528)

Amr Hesham via cfe-commits cfe-commits at lists.llvm.org
Thu Oct 9 13:58:51 PDT 2025


AmrDeveloper wrote:

I realised that in OGCG, it will call `EmitStmt(S.getTryBlock());` and in case that try block is empty, nothing will be generated. In our case, in the incubator, we added scope and use cir::TryOp but I think we can early return in the codegen if the try block is empty. I will do that in another PR and will update this PR after that to handle either non-catch all or try with body.

@andykaylor @bcardosolopes  

https://github.com/llvm/llvm-project/pull/162528


More information about the cfe-commits mailing list