mirror of
https://github.com/UpsilonNumworks/Upsilon.git
synced 2026-03-19 05:40:38 +01:00
[poincare] Evaluation: implement destructor of MatrixComplex
This commit is contained in:
committed by
LeaNumworks
parent
20543ec1aa
commit
8107d63a6b
@@ -63,7 +63,7 @@ public:
|
||||
std::complex<T> undef = std::complex<T>(NAN, NAN);
|
||||
return MatrixComplex<T>(&undef, 1, 1);
|
||||
}
|
||||
virtual ~MatrixComplex() {}
|
||||
~MatrixComplex();
|
||||
typename Poincare::Evaluation<T>::Type type() const override { return Poincare::Evaluation<T>::Type::MatrixComplex; }
|
||||
const std::complex<T> complexOperand(int i) const { return m_operands[i]; }
|
||||
int numberOfComplexOperands() const { return m_numberOfRows*m_numberOfColumns; }
|
||||
|
||||
@@ -131,6 +131,13 @@ MatrixComplex<T>::MatrixComplex(std::complex<T> * operands, int numberOfRows, in
|
||||
}
|
||||
}
|
||||
|
||||
template<typename T>
|
||||
MatrixComplex<T>::~MatrixComplex() {
|
||||
if (m_operands != nullptr) {
|
||||
delete [] m_operands;
|
||||
}
|
||||
}
|
||||
|
||||
template<typename T>
|
||||
Expression * MatrixComplex<T>::complexToExpression(Expression::ComplexFormat complexFormat) const {
|
||||
Expression ** operands = new Expression * [numberOfComplexOperands()];
|
||||
|
||||
Reference in New Issue
Block a user