1
0
mirror of https://github.com/paboyle/Grid.git synced 2025-06-13 20:57:06 +01:00

Added support for Ta to Lattice types

This commit is contained in:
neo
2015-06-04 18:29:55 +09:00
parent bb73569fd6
commit 949b6a7afa
3 changed files with 29 additions and 12 deletions

View File

@ -48,5 +48,16 @@ PARALLEL_FOR_LOOP
}
template<class vobj> inline auto Ta(const Lattice<vobj> &z) -> Lattice<decltype(Ta(z._odata[0]))>
{
Lattice<decltype(Ta(z._odata[0]))> ret(z._grid);
PARALLEL_FOR_LOOP
for(int ss=0;ss<z._grid->oSites();ss++){
ret._odata[ss] = Ta(z._odata[ss]);
}
return ret;
}
}
#endif