[Openmp-commits] [PATCH] D30271: [OpenMP] Missing virtual destructor in KMPAffinity
George Rokos via Phabricator via Openmp-commits
openmp-commits at lists.llvm.org
Wed Feb 22 13:40:11 PST 2017
grokos created this revision.
Class KMPAffinity has virtual functions, therefore it needs a virtual destructor too. If the virtual destructor is missing, the compiler emits a warning, compiling with `-Werror` makes the compilation fail.
Repository:
rL LLVM
https://reviews.llvm.org/D30271
Files:
runtime/src/kmp.h
Index: runtime/src/kmp.h
===================================================================
--- runtime/src/kmp.h
+++ runtime/src/kmp.h
@@ -629,6 +629,8 @@
};
void* operator new(size_t n);
void operator delete(void* p);
+ // Need virtual destructor
+ virtual ~KMPAffinity() = default;
// Determine if affinity is capable
virtual void determine_capable(const char* env_var) {}
// Bind the current thread to os proc
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D30271.89415.patch
Type: text/x-patch
Size: 451 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/openmp-commits/attachments/20170222/909c421f/attachment.bin>
More information about the Openmp-commits
mailing list