29 Aug
2002
29 Aug
'02
9:08 p.m.
It doesn't make sense to compare the two 'any' objects. I suppose boost::any could coerce the pointer into a long, and then apply a comparison operator, but the results of that comparison would be meaningless.
In order to compare the objects, you'll have to extract them from the any container using an any_cast. Which, of course, means you'll have to know the exact type of the object being held (or which type of a known set of types).
-- Jim
That makes sense. I suppose the best you could do is attempt to convert the unknown contained things into strings and compare those, but that's hardly effective. It turns out we didn't really need any anyways. ;-) Thanks, Bill