On Fri, Dec 7, 2012 at 8:57 AM, Klaim - Joël Lamotte <mjklaim@gmail.com> wrote:



On Fri, Dec 7, 2012 at 5:40 PM, Jeffrey Lee Hellrung, Jr. <jeffrey.hellrung@gmail.com> wrote:
Is mpl::is_sequence what you're looking for?

- Jeff


How did I miss that O___O
Thanks it's exactly what I was looking for but not at the right section of the doc.
It is supposed to work only with MPL containers, isn't it?

Yes, I believe so, but there is an extension framework within Boost.MPL to enable other types to be MPL-compatible sequences, if you needed that.

If you wanted to actually be more restrictive, I believe you might be able to retrieve the dispatch tag of the MPL sequence and check that it's a vector_tag, list_tag, etc. (I'm writing that all from fuzzy memory so I don't know if I have the terminology and names right). And I think if a type is not an MPL sequence, it returns some dummy "n/a" tag. Check the documentation and/or header files (specifically is_sequence.hpp, probably).

- Jeff