[PATCH] D146089: [Sema] Fix null pointer dereference handleAlwaysInlineAttr.

Craig Topper via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Mar 15 12:34:16 PDT 2023


craig.topper added inline comments.


================
Comment at: clang/test/Sema/attr-alwaysinline.cpp:32
+int foo(int x) {
+    if constexpr (D > 1)
+        [[clang::always_inline]] return foo<D-1>(x + 1);
----------------
erichkeane wrote:
> Also, I note the 'if constexpr' branch is unnecessary to reproduce this.
Yes, but I didn't bother to figure out what happened if the template recursivley instantiated without bound.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D146089/new/

https://reviews.llvm.org/D146089



More information about the cfe-commits mailing list