|
Boost : |
From: Pavel Vozenilek (pavel_vozenilek_at_[hidden])
Date: 2005-04-19 16:16:33
"Fredrik Blomqvist" wrote:
> I was browsing the docs for the upcoming circular_buffer component and
> noticed that the declaration of the comparison operators use the
> following, "traditional" style.
>
> template <class T, class Alloc>
> bool operator< (const circular_buffer<T,Alloc>& lhs, const
> circular_buffer<T,Alloc>& rhs);
>
> I think they should be templatized on both the lhs And rhs, like so:
>
> template <class T0, class Alloc0, class T1, class Alloc1>
> bool operator< (const circular_buffer<T0,Alloc0>& lhs, const
> circular_buffer<T1,Alloc1>& rhs);
>
> Not earth-shattering perhaps, but still a nice flexibility improvement
> IMHO. This scheme is used by
> several other boost components like for ex multi-index.
>
I remember this was suggested during review but perhaps
an common consensus on this should be formed first.
/Pavel
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk