#pragma once template struct mat; template inline constexpr typename mat::col_type col(mat const& m, int c) { typename mat::col_type v; for (int r = 0; r < R; r++) { v[r] = m[r][c]; } return v; } template inline constexpr vec<3, T> col(mat const& m, int c) { vec<3, T> v; for (int r = 0; r < 3; r++) { v[r] = m[r][c]; } return v; }