[clang] [Clang] Fix potential null pointer dereferences in Sema::AddInitializerToDecl (PR #94368)

via cfe-commits cfe-commits at lists.llvm.org
Mon Aug 5 00:58:27 PDT 2024


https://github.com/cor3ntin requested changes to this pull request.

Do you have any test that crashes without this change?
I agree with @feg208, we should assert Init is not null there (rather that silently return). If there are cases where init could in fact be null, we should add a test for it.

Thanks!

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


More information about the cfe-commits mailing list