data setter API only valid for cpu backend
Issue, in Tensor we have this function:
template<typename expectedType> void set(NbElts_t const idx, expectedType const value)
It's implementation relies on storage being on CPU and, as it is templated, its code is exposed.
Yet the body does not rely on expectedType (at least in !13 (closed)).
The design of this function must be thought again:
- to work for any backend
- for efficiency, if possible (obvious implementation would be to wrap a call to a virtual function of TensorImpl; perhaps that an implementation templated with respect to the backend is possible?)
- to be wrappable for python (yet there is still the possibility to wrap it into a lambda)
Related to #21 (closed)
Edited by Maxence Naud