ENH: polynomial - added clone()

This commit is contained in:
Andrew Heather
2020-12-16 14:21:10 +00:00
committed by Mattijs Janssens
parent dfe98fdf67
commit 9f5b8d0ebb

View File

@ -103,6 +103,12 @@ public:
//- Copy constructor
explicit Polynomial(const Polynomial& poly);
//- Construct and return a clone
virtual tmp<Function1<Type>> clone() const
{
return tmp<Function1<Type>>(new Polynomial<Type>(*this));
}
//- Destructor
virtual ~Polynomial() = default;