Re: Template Code compile errors
Thanks for your interest in this issue !
'T' is for floating-point types like 'double', 'float', etc ...
No, I have not contacted the authors on this, but this code is intended to
run under unix. The strictly 'number crunching' codes I am trying to compile
shouldn't really care about unix or windows or whatever. My feeling is that
it should compile in visual studio anyway, more or less ...
Here is the 'verbatim' declaration -
template<typename T, template<typename U> class Lattice>
void Cell<T,Lattice>:: iniEquilibrium(T rho, const T u[Lattice<T>::d]) {
for (int iPop=0; iPop<Lattice<T>::q; ++iPop) {
T uSqr = util::normSqr<T,Lattice<T>::d>(u);
f[iPop] = lbHelpers<T,Lattice>::equilibrium(iPop, rho, u, uSqr);
}
}
And the 'verbatim' definition -
template<typename T, template<typename U> class Lattice>
class Cell {
.
.
.
public:
/// Initialize all f values to their local equilibrium
void iniEquilibrium(T rho, const T u[Lattice<T>::d]);
They seem to be identical - what am I missing ?
--
gordon