diff options
author | Aaron Ballman <aaron@aaronballman.com> | 2022-08-19 15:51:53 -0400 |
---|---|---|
committer | Aaron Ballman <aaron@aaronballman.com> | 2022-08-19 15:53:19 -0400 |
commit | cda093681bad901e64d0f6898d15121ab49cb074 (patch) | |
tree | 0f0973bccc2176739e1183b0df47291698ee32ba /lldb/packages/Python/lldbsuite/test/configuration.py | |
parent | e412bac9125a806d147f4f545dd057fac0b4a8f0 (diff) | |
download | llvm-cda093681bad901e64d0f6898d15121ab49cb074.zip llvm-cda093681bad901e64d0f6898d15121ab49cb074.tar.gz llvm-cda093681bad901e64d0f6898d15121ab49cb074.tar.bz2 |
Update coding standards for constexpr if statements; NFC
We currently suggest that users not use an else clause after a return
statement in a prior if branch. e.g.,
if (foo)
return 1;
else // Should remove this else clause
return 10;
however, this suggestion is incorrect for a constexpr if statement
because one of the two branches will be a discarded statement and thus
can impact template instantiation behavior. This updates the coding
standard to make it clear that it's okay to have a return after an else
in a constexpr if statement.
I think this is an NFC change to the intent of the rule, which is why
I've not started an RFC for the changes.
Differential Revision: https://reviews.llvm.org/D132232
Diffstat (limited to 'lldb/packages/Python/lldbsuite/test/configuration.py')
0 files changed, 0 insertions, 0 deletions