[polly] r248764 - Make Polly -Wdeprecated clean by explicitly making BlockGenerator copy constructible

David Blaikie via llvm-commits llvm-commits at lists.llvm.org
Mon Sep 28 17:00:30 PDT 2015


Author: dblaikie
Date: Mon Sep 28 19:00:29 2015
New Revision: 248764

URL: http://llvm.org/viewvc/llvm-project?rev=248764&view=rev
Log:
Make Polly -Wdeprecated clean by explicitly making BlockGenerator copy constructible

This is a bit of an awkward API and I'm not sure what the right solution
is. Having a publicly copy constructible base class makes it easy to
accidentally slice derived objects in a number of contexts.

Modified:
    polly/trunk/include/polly/CodeGen/BlockGenerators.h

Modified: polly/trunk/include/polly/CodeGen/BlockGenerators.h
URL: http://llvm.org/viewvc/llvm-project/polly/trunk/include/polly/CodeGen/BlockGenerators.h?rev=248764&r1=248763&r2=248764&view=diff
==============================================================================
--- polly/trunk/include/polly/CodeGen/BlockGenerators.h (original)
+++ polly/trunk/include/polly/CodeGen/BlockGenerators.h Mon Sep 28 19:00:29 2015
@@ -161,7 +161,9 @@ public:
   void finalizeSCoP(Scop &S);
 
   /// @brief An empty destructor
-  virtual ~BlockGenerator(){};
+  virtual ~BlockGenerator() = default;
+
+  BlockGenerator(const BlockGenerator &) = default;
 
 protected:
   PollyIRBuilder &Builder;




More information about the llvm-commits mailing list