jfb added a comment.

Maybe you should test `nullptr` as well, given that it's all padding?



================
Comment at: clang/test/SemaCXX/constexpr-builtin-bit-cast.cpp:407
+
+constexpr bool test_bad_bool = bit_cast<bool>('A'); // expected-error {{must 
be initialized by a constant expression}} expected-note{{in call}}
+
----------------
Sanity-check: `0` and `1` work? IIRC we had a discussion about whether `false` 
was `0` and `true` was `1`, and we concluded that `false` was indeed `0` but 
`true` wasn't specified to be `1`.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D76323/new/

https://reviews.llvm.org/D76323



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to