On 14/04/16 06:34 -0400, Igor Gnatenko wrote:
ascxx/curve.h: class Curve : public Instanc{ friend class std::vector<Curve>; private: friend class Plot; explicit Curve(const Instanc &); Curve(); public: Curve(const Curve &); std::vector<double> x; std::vector<double> y; const std::string getLegend() const; /** Get the curve format string, as used by matplotlib. Documented here: http://matplotlib.sourceforge.net/api/axes_api.html#matplotlib.axes.Axes.plot (This value is not used by the Tcl/Tk GUI.) */ const std::string getFormat() const; }; ascxx/ascpy.i: %ignore Curve::Curve(); %include "curve.h" It should be ignored by SWIG, but looks like it's not...
I don't think that's the problem. In C++98 constructing std::vector<X> v(1); would invoke X's default constructor in the caller's context, so if the default constructor is private then the caller must be a member or friend of X. In C++11 the default constructor will be invoked deep inside std::vector, or one of its helper functions. The code is basically invalid in C++11. It should either make the default constructor public (the simplest fix), or change how the vector is constructed (which seems to come from Swig, so might be difficult). -- devel mailing list devel@xxxxxxxxxxxxxxxxxxxxxxx http://lists.fedoraproject.org/admin/lists/devel@xxxxxxxxxxxxxxxxxxxxxxx