[llvm] r294443 - Adding virtual destructor for PredicateBase.
Alexander Kornienko via llvm-commits
llvm-commits at lists.llvm.org
Wed Feb 8 05:28:28 PST 2017
Author: alexfh
Date: Wed Feb 8 07:28:27 2017
New Revision: 294443
URL: http://llvm.org/viewvc/llvm-project?rev=294443&view=rev
Log:
Adding virtual destructor for PredicateBase.
A virtual destructor is needed, since the derived classes are stored in
`iplist<PredicateBase> AllInfos;` and, apparently, ilist_node doesn't have a
virtual destructor.
Modified:
llvm/trunk/include/llvm/Transforms/Utils/PredicateInfo.h
Modified: llvm/trunk/include/llvm/Transforms/Utils/PredicateInfo.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/Transforms/Utils/PredicateInfo.h?rev=294443&r1=294442&r2=294443&view=diff
==============================================================================
--- llvm/trunk/include/llvm/Transforms/Utils/PredicateInfo.h (original)
+++ llvm/trunk/include/llvm/Transforms/Utils/PredicateInfo.h Wed Feb 8 07:28:27 2017
@@ -106,6 +106,7 @@ public:
PredicateBase(const PredicateBase &) = delete;
PredicateBase &operator=(const PredicateBase &) = delete;
PredicateBase() = delete;
+ virtual ~PredicateBase() = default;
protected:
PredicateBase(PredicateType PT, Value *Op, CmpInst *Comparison)
More information about the llvm-commits
mailing list