[PATCH] D46234: Mark if a null statement is the result of constexpr folding
Richard Smith - zygoloid via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Sun Apr 29 13:20:17 PDT 2018
rsmith added a comment.
In https://reviews.llvm.org/D46234#1082332, @xazax.hun wrote:
> In https://reviews.llvm.org/D46234#1082307, @rsmith wrote:
>
> > Perhaps we should just use a null pointer for the not-instantiated arm of an `if constexpr` instead, rather than tracking a flag on an empty statement that is meaningless for real empty statements.
>
>
> I will look into that, thanks. I wonder if any of the code assumes that the than branch always present.
I expect some code does. But this is fundamentally a special property of an `if constexpr` statement, not of an empty statement, so I think it makes most sense that whatever special handling we choose to use for this should live in the `IfStmt`.
Repository:
rC Clang
https://reviews.llvm.org/D46234
More information about the cfe-commits
mailing list