
8 Jul
2010
8 Jul
'10
7:21 a.m.
Peter Bartlett wrote:
Quoting Timothy Madden
: boost::make_recursive_variant< >::type can serve my purpose well, except that I do not need a variant in my structure, I just need the structure to be recursive. Is there a way to get the recursive-definition behavior of make_recursive_variant<>, without the variant ?
Also I am curios: how is such a recursive definition possible ? How does make_recursive_variant implement it ?
Sounds like a job for boost::recursive_wrapper, which variant uses under the hood.
I would like the possibility to create the type in-place, which make_recursive_variant offers (recursive_wrapper requires a type already declared). Timothy Madden