================
@@ -1902,16 +1902,18 @@ class IRBuilderBase {
}
Value *CreateConstGEP2_32(Type *Ty, Value *Ptr, unsigned Idx0, unsigned Idx1,
- const Twine &Name = "") {
+ const Twine &Name = "",
+ GEPNoWrapFlags NWFlags = GEPNoWrapFlags::none()) {
Value *Idxs[] = {
ConstantInt::get(Type::getInt32Ty(Context), Idx0),
ConstantInt::get(Type::getInt32Ty(Context), Idx1)
};
- if (auto *V = Folder.FoldGEP(Ty, Ptr, Idxs, GEPNoWrapFlags::none()))
+ if (auto *V =
+ Folder.FoldGEP(Ty, Ptr, Idxs, /*IsInBounds=*/NWFlags.isInBounds()))
----------------
nikic wrote:
Shouldn't this be?
```suggestion
Folder.FoldGEP(Ty, Ptr, Idxs, NWFlags))
```
https://github.com/llvm/llvm-project/pull/99538
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits