From 03f70f6ba9622bb2840a14fc50ac72201cc533b5 Mon Sep 17 00:00:00 2001 From: Mikko Rasa Date: Sat, 18 May 2013 21:31:41 +0300 Subject: [PATCH] Fix Matrix template copy constructor A different version of the template is a different class, so the data member can't be accessed directly. --- source/linal/matrix.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/source/linal/matrix.h b/source/linal/matrix.h index ff73165..83a64f5 100644 --- a/source/linal/matrix.h +++ b/source/linal/matrix.h @@ -54,9 +54,11 @@ inline Matrix::Matrix(const T *d) template template -inline Matrix::Matrix(const Matrix &m) +inline Matrix::Matrix(const Matrix &other) { - std::copy(m.data, m.data+M*N, data); + for(unsigned i=0; i -- 2.43.0