[PATCH] D134744: [clang][Interp] Implement rem opcode
Shafik Yaghmour via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Tue Sep 27 22:04:26 PDT 2022
shafik added inline comments.
================
Comment at: clang/lib/AST/Interp/Interp.h:164
+
+ if (RHS.isZero()) {
+ const SourceInfo &Loc = S.Current->getSource(OpPC);
----------------
You also need to catch when the result is not representable e.g `INT_MIN % -1`
see `CheckICE(...)`
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D134744/new/
https://reviews.llvm.org/D134744
More information about the cfe-commits
mailing list