|
Boost : |
Subject: Re: [boost] [any] Multimethod for boost::any and modified boost::any to fit multi method
From: Andrey Semashev (andrey.semashev_at_[hidden])
Date: 2009-02-12 15:27:18
Mathias Gaunard wrote:
> A while ago, I offered something like this
>
> any m = 0;
> apply_visitor<int, double, A>(f, m);
>
> or alternatively,
> apply_visitor(f, m); with f specifying all overloads in some
> compile-time reflection structure.
>
> unfortunately, it cannot be made constant-time because std::type_info
> sucks.
FWIW, I would be really interested in this feature even if it's not
constant time. May I hope it will appear in trunk one day?
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk