diff --git a/lib/Transforms/Instrumentation/MemorySanitizer.cpp b/lib/Transforms/Instrumentation/MemorySanitizer.cpp index 74334093450..ed0f89bfb59 100644 --- a/lib/Transforms/Instrumentation/MemorySanitizer.cpp +++ b/lib/Transforms/Instrumentation/MemorySanitizer.cpp @@ -186,8 +186,8 @@ private: /// \brief An empty volatile inline asm that prevents callback merge. InlineAsm *EmptyAsm; - friend class MemorySanitizerVisitor; - friend class VarArgAMD64Helper; + friend struct MemorySanitizerVisitor; + friend struct VarArgAMD64Helper; }; } // namespace @@ -336,6 +336,8 @@ struct VarArgHelper { /// This method is called after visiting all interesting (see above) /// instructions in a function. virtual void finalizeInstrumentation() = 0; + + virtual ~VarArgHelper() {} }; struct MemorySanitizerVisitor;