[PATCH] D132098: [clang][Interp] Implement inv and neg unary operations

Timm Bäder via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Aug 17 23:25:44 PDT 2022


tbaeder added inline comments.


================
Comment at: clang/lib/AST/Interp/ByteCodeExprGen.cpp:123
 
-  default: {
-    // TODO: implement other casts.
-    return this->bail(CE);
-  }
+  case CK_IntegralToBoolean:
+    if (Optional<PrimType> T = classify(SubExpr->getType())) {
----------------
Implementing the `IntegralToBoolean` cast is not necessary for this change, but makes more tests possible.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D132098



More information about the cfe-commits mailing list