[PATCH] D76323: [AST] Fix handling of long double and bool in __builtin_bit_cast

Louis Dionne via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Fri Mar 20 08:38:28 PDT 2020


ldionne accepted this revision.
ldionne added a comment.
This revision is now accepted and ready to land.

LGTM at high level, but I'm not really familiar with the code.



================
Comment at: clang/lib/AST/ExprConstant.cpp:6365
+    const llvm::fltSemantics &Semantics = Info.Ctx.getFloatTypeSemantics(Ty);
+    unsigned NumBits = APFloat::semanticsSizeInBits(Semantics);
+    assert(NumBits % 8 == 0);
----------------
`semanticsSizeInBits` is the number of bits actually used in the type?


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

https://reviews.llvm.org/D76323





More information about the cfe-commits mailing list