[PATCH] D141497: [clang][Interp] Record initialization via conditional operator
Erich Keane via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Tue Jan 17 07:00:16 PST 2023
erichkeane added inline comments.
================
Comment at: clang/lib/AST/Interp/ByteCodeExprGen.h:200
+ using ExprVisitorFunc = std::function<bool(const Expr *)>;
+ bool visitConditional(const AbstractConditionalOperator *E,
+ ExprVisitorFunc VisitFunc);
----------------
tbaeder wrote:
> tbaeder wrote:
> > erichkeane wrote:
> > > I'd probably rather make this a template taking a functor, rather than bringing in the atrocities that come with std::function.
> > Alright, will look into that
> Done. Not sure if this is exactly how you meant it to look. Feels a bit inelegant.
This actually probably needs to be a non-member now, since its only used in the .cpp.
while I DO dislike that it was using std::function (probably because of captures in the lambdas?), I now suspect this is worse if we can't have it in the header, right?
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D141497/new/
https://reviews.llvm.org/D141497
More information about the cfe-commits
mailing list