
6 Jun
2006
6 Jun
'06
9:21 p.m.
On 6/6/06, Yuval Ronen <ronen_yuval@yahoo.com> wrote:
Christopher Kohlhoff wrote:
tempalte <endianness E> struct message { endian<E, short, 2> first; endian<E, int, 4> second; endian<E, int, 4> third; ... };
On the other hand, the definition of struct message, can benefit from it, I agree. So to provide a solution for the struct, I suggest to add a 'type selector' to the suggestion I described (too many times) in this thread.
How about template template parameters? template <template <typename> class E> struct message { E< exact_int_t<2> > first; E< exact_int_t<4> > second; E< exact_int_t<4> > third; ... }; Though that might unnecessarily restrict the possible compilers. ~ Scott McMurray