Mat Marcus <[EMAIL PROTECTED]> writes: >> Well, that's a slightly different issue and you may be right. On the >> other hand, you can always define a type which implements those >> implicit constructors: >> >> template <class T> >> struct implicit_optional : optional<T> >> { >> implicit_optional() {} >> implicit_optional(optional<T> const& x) : optional<T>(x) {} >> implicit_optional(T const& x) : optional<T>(x) {} >> }; >> >> You could use that in your interfaces. > > And then slice it back to option internally to avoid bool weirdness?
I didn't have that in mind, no. Why slice when you can avoid a copy instead? and what is "bool weirdness"? > Might work out. Got any good ideas to help use optional with tie? Seems to me you could use a similar shim, as long as it had a const assignment operator: tie(shim(foo), shim(bar)) = ... ; Not very generic, but it should work out. -- Dave Abrahams Boost Consulting www.boost-consulting.com _______________________________________________ Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost