[PATCH] D135569: [clang][Interp] Don't run functions immediately after compiling them
Aaron Ballman via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Wed Oct 12 06:51:24 PDT 2022
aaron.ballman accepted this revision.
aaron.ballman added a comment.
This revision is now accepted and ready to land.
I think this change makes sense to me. Ultimately, this API is about the potential to be constexpr, so there's no need to pay for the expense of running the function with some ginned up arguments -- if we can compile it as a constexpr function, it's potentially constexpr.
================
Comment at: clang/lib/AST/Interp/Context.cpp:44-47
if (!Func->isConstexpr())
return false;
+ return true;
----------------
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D135569/new/
https://reviews.llvm.org/D135569
More information about the cfe-commits
mailing list