
30 Nov
2012
30 Nov
'12
4:18 a.m.
Is there any way to determine when a type is an MPL placeholder expression ? I can determine whether a type is a metafunction class ( it has a class template called 'apply' ), but I can't think of any sure way to determine whether or not a type is a placeholder expression. Ideally if a type in one of my templates is an MPL lambda expression ( its either a metafunction class or placeholder expression ) I want to invoke it with some compile-time data, otherwise I want to do something else with that type. Of course a less elegant solution is to have another template boost::mpl::bool_ parameter telling which it is but I was hoping to avoid it if I can figure it out myself.