David Abrahams wrote:
Daniel Frey <[EMAIL PROTECTED]> writes:

When looking at the current:

class X : boost::addable< X >
{
   X& operator+=( const X& );
};

I wonder if addable is a good name. I thought that the classes are
named by the operator that is provided by the user and that they add
the operators that are based on it. Like here:

class Y : boost::less_than_comparable< Y >
{
   friend bool operator<( const Y&, const Y& );
};

That given, the new class should be called 'addable', the current
class should probably be called 'add_assignable' or something like
that. But that would break the interface :(( Thoughts, anyone?

If anything, I think it's less_than_comparable which should change.

I was just pointing out an inconsistency and the problem to find a name for the newly proposed helpers. I think that the current names are really intuitive (although not consistent) and that we should keep them - if not for anything else than at least for compatibility. Still we need to find (hopefully intuitive) names for the new helpers that Daryle proposed. Let's make a list for possible helper class names providing operator+= for classes that have operator+:


add_assignable (opposite semantics of above's quote)
reversed_addable (IMHO nasty, but an option anyway)
addable_assign
assign_addable
[your cool idea here :)]

--
Daniel Frey

aixigo AG - financial training, research and technology
Schloß-Rahe-Straße 15, 52072 Aachen, Germany
fon: +49 (0)241 936737-42, fax: +49 (0)241 936737-99
eMail: [EMAIL PROTECTED], web: http://www.aixigo.de


_______________________________________________ Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost

Reply via email to