This revision was landed with ongoing or failed builds.
This revision was automatically updated to reflect the committed changes.
Closed by commit rG881547db03a6: [clang][Interp] Implement add and sub compound
assign operators (authored by tbaeder).
Changed prior to commit:
https://reviews.llvm
aaron.ballman accepted this revision.
aaron.ballman added a comment.
This revision is now accepted and ready to land.
LGTM!
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D136528/new/
https://reviews.llvm.org/D136528
___
cfe-commits mailing lis
tbaeder added inline comments.
Comment at: clang/test/AST/Interp/literals.cpp:426
+ }
+ static_assert(subAll(213) == 0);
+
aaron.ballman wrote:
> We also need tests for failure situations:
> ```
> constexpr int func() {
> int i = __INT_MAX__;
> i += 1; // o
tbaeder updated this revision to Diff 470138.
tbaeder marked 2 inline comments as done.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D136528/new/
https://reviews.llvm.org/D136528
Files:
clang/lib/AST/Interp/ByteCodeExprGen.cpp
clang/lib/AST/Interp/ByteCodeExprGen.h
clang/test/AST/I
aaron.ballman added inline comments.
Comment at: clang/test/AST/Interp/literals.cpp:412
+
+ constexpr int getTwo() {
+int i = 1;
I'd also like some test cases where the result of the operation is discarded.
e.g.,
```
constexpr int func() {
int i = 12;
i
tbaeder created this revision.
tbaeder added reviewers: aaron.ballman, erichkeane, tahonermann, shafik.
Herald added a project: All.
tbaeder requested review of this revision.
Herald added a project: clang.
Herald added a subscriber: cfe-commits.
Repository:
rG LLVM Github Monorepo
https://revi