NoQ added a comment. In D101635#2731210 <https://reviews.llvm.org/D101635#2731210>, @steakhal wrote:
> Does anyone have an idea how to prevent such a silly mistake from happening > again? Maybe use more optionals? I.e., `castRegion` may fail, so let's change it to return `Optional<const MemRegion *>` where the pointer is always non-null when present? In many cases it's probably unnecessary but when a function can return null //for poorly predictable reasons// (eg., like in this case, the region turning out to have symbolic offset after a potentially unlimited number of unwraps) it's probably worth it. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D101635/new/ https://reviews.llvm.org/D101635 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits