Open changephilip opened 5 years ago
I don't thinks that's possible right now. BOOST_COMPUTE_ADAPT_STRUCT
would have to know dependencies of the struct it's adapting to inject required type definition into kernels.
I think if you look how BOOST_COMPUTE_ADAPT_STRUCT
is implemented, you can implement similar variadic macro (C++11 would be required and/or GNU extension), where the variadic arguments are dependencies (required types).
Hello! I use code like below in my program.
While I compile the program , the compiler report some errors about redefinition:
/boost/compute/type_traits/type_name.hpp:119:24: error: redefinition of 'const char* boost::compute::type_name() [with T= MyStructB]'
I wonder whether I could nested a struct in another struct.