-Itay
"Rodolfo Lima" <[EMAIL PROTECTED]> wrote in message b2tm6v$9o7$[EMAIL PROTECTED]">news:b2tm6v$9o7$[EMAIL PROTECTED]... > How different is boost::any from this new variant library? Don't they > address the same issue? > In short: (1) boost::any can accept a value of any possible type. boost::variant accepts only values of a finite set of types, which are passed as template parameters (2) boost::any offers a query-based mechanism for accessing its held value: any_cast<T>(a); This operation may fail (at runtime). The equivalent facility of boost::variant is: apply_visitor(a_visitor, a_variant). This operation will fail at *compile-time* if a_visitor is not a valid visitor for a_variant. More details can about visitation can be found in variant's docs. -Itay _______________________________________________ Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost