Incorrect usage of NDEBUG to guard ABI changes can prevent clients
from enabling assertions for their C++ code while having assertions in
LLVM turned off. So we use LLVM_ENABLE_ABI_BREAKING_CHECKS instead, as
described in llvm/docs/ProgrammersManual.rst. Most types already use this
macro, however, there were a couple of stragglers in ValueHandle.h, which
are fixed by this revision.
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
Looks good to me - couple of side comments, possibly more directed at other reviewers to discuss/consider.
llvm/include/llvm/IR/ValueHandle.h | ||
---|---|---|
290 | Follow-up/preliminary commit could probably remove the <ValueTy> from this line, I think. | |
447 | Would it be OK (follow-up/preliminary commit) to move final out of this block? So the type is always final - or does that break something else? |
llvm/include/llvm/IR/ValueHandle.h | ||
---|---|---|
447 | Interesting; I hadn't considered putting final on a class that doesn't inherit from anything, but I imagine you're right and this could be moved out. |
llvm/include/llvm/IR/ValueHandle.h | ||
---|---|---|
489 | Missed this usage (probably worth building with/without ABI breaking checks in the future to validate these sort of changes) which breaks the non-abi-breaking-checks build. Oh, and some death unit tests no longer worked/needed to be protected by ABI_BREAKING_CHECKS as well as !NDEBUG. Fixed in: 3503c856819efc01ce210fa56e597ddfb7a4c1a1 |
Follow-up/preliminary commit could probably remove the <ValueTy> from this line, I think.