From 450a652bcf708bfa675f78faebc611d900fa86ab Mon Sep 17 00:00:00 2001 From: Duy-Nguyen Ta Date: Mon, 12 Sep 2016 18:47:04 -0400 Subject: [PATCH] pxd hack: always add copy constructor by default --- wrap/Constructor.cpp | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/wrap/Constructor.cpp b/wrap/Constructor.cpp index 9e56b7d39..e306a51f0 100644 --- a/wrap/Constructor.cpp +++ b/wrap/Constructor.cpp @@ -131,11 +131,9 @@ bool Constructor::hasDefaultConstructor() const { /* ************************************************************************* */ void Constructor::emit_cython_pxd(FileWriter& pxdFile, Str className) const { - // if it can ever be constructed, add the default copy constructor by default - if (nrOverloads() > 0) { - pxdFile.oss << "\t\t" << className << "(const " << className - << "&) except +\n"; - } + // HACK HACK: always add the default copy constructor by default + pxdFile.oss << "\t\t" << className << "(const " << className + << "&) except +\n"; for (size_t i = 0; i < nrOverloads(); i++) { ArgumentList args = argumentList(i);