These macros can only be used for values of type bool.
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
- Build Status
Buildable 45300 Build 47071: arc lint + arc unit
Event Timeline
| libc/utils/UnitTest/Test.h | ||
|---|---|---|
| 91 | Ah sorry, this was supposed to be a demo patch. I will update this to make it review ready and update soon. | |
I am convinced (thanks to @gchatelet) that we can safely extend our macros to bool. Some of them, like EXPECT_LE might not be meaningful for bool, but I do not see any reason to make special effort to prevent such uses.
| libc/utils/UnitTest/Test.h | ||
|---|---|---|
| 68–69 | @gchatelet will be happy about this change :) | |
| 190–191 | Could we shorten this to EXPECT_EQ(VAL, true)? | |
| libc/utils/UnitTest/Test.h | ||
|---|---|---|
| 190–191 | Indeed! | |
@gchatelet will be happy about this change :)