|
Boost Users : |
Subject: Re: [Boost-users] [MPL] Permutations of a List of Types
From: Steven Watanabe (watanabesj_at_[hidden])
Date: 2010-12-30 11:14:51
AMDG
On 12/22/2010 1:18 PM, Edward Terchunian wrote:
> I am trying to create a list containing the permutations of a given type list.
>
> The below code seems to function, though without the intended result,
> when I use a specified list instead of generating a new list by
> removing from the actual input. This is demonstrated by the difference
> between permutation_helper and broken_helper below.
>
> Am I using remove incorrectly, or am I running into a different problem?
> <snip>
>
> template< typename T>
> struct permutations;
>
> template<typename value>
> struct permutations<mpl::list1< value> >: mpl::list1<mpl::list1< value> > {};
A list containing 1 element is not guaranteed to be a
specialization of list1.
In Christ,
Steven Watanabe
Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net