Boost Users :
Subject: Re: [Boost-users] Tips on implementing a function queue with unique queue items (compare function problem)
From: Nat Goodspeed (nat_at_[hidden])
Date: 2009-05-12 19:41:54
Peter Åberg wrote:
> Anyone have a tip or pointer regarding how to implement a function queue
> with unique items?
You're right that we can't compare two boost::function objects, but it
*is* permitted to compare a boost::function with an rvalue that could
initialize it. If you make your push() method a template accepting an
argument of arbitrary type, presumably you could compare each existing
item with that new value before storing it into the deque.
Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net