diff -aur contrib/examples/banded_view_test.cc contrib/examples/banded_view_test.cc --- contrib/examples/banded_view_test.cc 2005-07-05 15:11:50.000000000 +0000 +++ contrib/examples/banded_view_test.cc 2005-08-30 11:18:34.000000000 +0000 @@ -15,43 +15,43 @@ print_all_matrix(A); std::cout << std::endl; - typedef rows_type<Matrix>::type RowMatrix; + typedef typename rows_type<Matrix>::type RowMatrix; std::cout << "rows banded" << std::endl; //begin - band_view<RowMatrix>::type B(2, 1, A); + typename band_view<RowMatrix>::type B(2, 1, A); //end print_all_banded(B, 2, 1); print_row(B); std::cout << std::endl; std::cout << "columns banded" << std::endl; - typedef columns_type<Matrix>::type ColMatrix; - band_view<ColMatrix>::type C(2, 1, columns(A)); + typedef typename columns_type<Matrix>::type ColMatrix; + typename band_view<ColMatrix>::type C(2, 1, columns(A)); print_all_banded(C, 2, 1); print_column(C); std::cout << std::endl; std::cout << "rows lower triangle" << std::endl; - triangle_view<RowMatrix, lower>::type L(A); + typename triangle_view<RowMatrix, lower>::type L(A); print_all_banded(L, M-1, 0); print_row(L); std::cout << std::endl; std::cout << "rows unit upper triangle" << std::endl; - triangle_view<RowMatrix, unit_upper>::type U(A); + typename triangle_view<RowMatrix, unit_upper>::type U(A); print_all_banded(U, -1, N-1); print_row(U); std::cout << "columns lower triangle" << std::endl; - triangle_view<ColMatrix, lower>::type CL(columns(A)); + typename triangle_view<ColMatrix, lower>::type CL(columns(A)); print_all_banded(CL, M-1, 0); print_column(CL); std::cout << std::endl; std::cout << "columns unit upper triangle" << std::endl; - triangle_view<ColMatrix, unit_upper>::type CU(columns(A)); + typename triangle_view<ColMatrix, unit_upper>::type CU(columns(A)); print_all_banded(CU, -1, N-1); print_column(CU); //begin diff -aur mtl/dimension.h mtl/dimension.h --- mtl/dimension.h 2005-07-05 15:11:49.000000000 +0000 +++ mtl/dimension.h 2005-08-30 11:10:27.000000000 +0000 @@ -35,8 +35,8 @@ inline dimension(size_type m_, size_type n_) : m(m_), n(n_) { } inline dimension& operator=(const dimension& x) { m = x.m; n = x.n; return *this; } - inline size_type first() const { return M ? M : m; } - inline size_type second() const { return N ? N : n; } + inline size_type first() const { return M ? (size_type)M : m; } + inline size_type second() const { return N ? (size_type)N : n; } inline bool is_static() const { return M != 0; } inline transpose_type transpose() const { return transpose_type(n, m); } /* protected: */ diff -aur mtl/external_vector.h mtl/external_vector.h --- mtl/external_vector.h 2005-07-05 15:11:49.000000000 +0000 +++ mtl/external_vector.h 2005-08-30 11:10:27.000000000 +0000 @@ -74,7 +74,7 @@ return data_[n]; } // Size Methods - inline size_type size() const { return N ? N : size_; } + inline size_type size() const { return N ? (size_type)N : size_; } inline void set_size(size_type n) { size_ = n; } // Memory Access diff -aur mtl/linalg_vec.h mtl/linalg_vec.h --- mtl/linalg_vec.h 2005-07-05 15:11:49.000000000 +0000 +++ mtl/linalg_vec.h 2005-08-30 11:10:27.000000000 +0000 @@ -515,7 +515,7 @@ /* Size Methods */ //: The size of the vector //!wheredef: Container - inline size_type size() const { return N ? N : size_; } + inline size_type size() const { return N ? (size_type)N : size_; } //: The number of non-zeroes in the vector //!wheredef: Vector diff -aur mtl/matrix_implementation.h mtl/matrix_implementation.h --- mtl/matrix_implementation.h 2005-07-05 15:11:49.000000000 +0000 +++ mtl/matrix_implementation.h 2005-08-30 11:15:36.000000000 +0000 @@ -939,7 +939,7 @@ template<class Matrix> inline typename rows_type<Matrix>::type rows(const Matrix& A) { - return rows_type<Matrix>::type(A, do_strided()); + return typename rows_type<Matrix>::type(A, do_strided()); } //: Access the column-wise view of the matrix @@ -954,7 +954,7 @@ template<class Matrix> inline typename columns_type<Matrix>::type columns(const Matrix& A) { - return columns_type<Matrix>::type(A, do_strided()); + return typename columns_type<Matrix>::type(A, do_strided()); } //: Swap the orientation of a matrix. diff -aur mtl/mtl.h mtl/mtl.h --- mtl/mtl.h 2005-07-05 15:11:49.000000000 +0000 +++ mtl/mtl.h 2005-08-30 11:16:24.000000000 +0000 @@ -139,7 +139,7 @@ void scale_dim(Vector& x, const T& alpha, oned_tag) { - oned_scale(x, alpha, dim_n<Vector>::RET()); + oned_scale(x, alpha, typename dim_n<Vector>::RET()); } template <class Matrix, class T> @@ -233,7 +233,7 @@ inline typename linalg_traits<Vector>::magnitude_type one_norm(const Vector& x, oned_tag) { - return oned_one_norm(x, dim_n<Vector>::RET()); + return oned_one_norm(x, typename dim_n<Vector>::RET()); } @@ -285,7 +285,7 @@ inline typename linalg_traits<Vector>::magnitude_type two_norm(const Vector& x) { - return oned_two_norm(x, dim_n<Vector>::RET()); + return oned_two_norm(x, typename dim_n<Vector>::RET()); } //: add square @@ -2993,7 +2993,7 @@ MTL_ASSERT(x.size() <= y.size(), "mtl::ele_mult()"); MTL_ASSERT(x.size() <= z.size(), "mtl::ele_mult()"); - ele_mult(x, y, z, dim_n<VecX>::RET()); + ele_mult(x, y, z, typename dim_n<VecX>::RET()); } @@ -3070,7 +3070,7 @@ swap(VecX& x, VecY& y, oned_tag) MTL_THROW_ASSERTION { MTL_ASSERT(x.size() <= y.size(), "mtl::swap()"); - swap(x, y, dim_n<VecX>::RET()); + swap(x, y, typename dim_n<VecX>::RET()); } @@ -3143,7 +3143,7 @@ inline T dot(const VecX& x, const VecY& y, T s, dense_tag, dense_tag) { - return dot(x, y, s, dim_n<VecX>::RET()); + return dot(x, y, s, typename dim_n<VecX>::RET()); } template <class InputIterator1, class InputIterator2, class T>