
After some research, I found this post: http://lists.boost.org/boost-users/2007/05/27648.php that provides a 2-sequence cartesian product metafunction that I will try to use to have the product of the 3 sequences I have. Rds, -----Original Message----- From: boost-users-bounces@lists.boost.org [mailto:boost-users-bounces@lists.boost.org] On Behalf Of Steven Watanabe Sent: 29 May 2008 23:53 To: boost-users@lists.boost.org Subject: Re: [Boost-users] variant<> number of template arguments AMDG Hicham Mouline wrote:
Question1: is the maximum number of variant<> arguments extendable?
The easiest way is to use make_variant_over which takes an MPL sequence.
Question2: Below, some of the variants I have are full template specs.
Is there a way to write the variant<> typedef with templates instead and have
the operator() of the static visitor a template member.
I'm not sure what you want. If the members of the variant have a common interface, (For example if they all have a nested integer constant called value) Then you can make the static visitor operator() a template and use this common interface. In Christ, Steven Watanabe