|
Boost : |
Subject: Re: [boost] [Review] Type Traits Extension ending tomorrow
From: Stewart, Robert (Robert.Stewart_at_[hidden])
Date: 2011-03-18 13:12:58
John Maddock wrote:
>
> >> I'd prefer is_plus_assignable if we go that route.
> >
> > is_add_assignable
> >
> > (The operation is addition followed by assignment, not plus
> > followed by assignment.)
>
> How do you pronounce C++ ? ;-)
If you're going that route, then it's is_plus_equal-able, not is_plus_assignable!
However, += is the add-and-assign operator, even if you might read the symbol aloud as plus-equal.
For grins, I consulted _C: A Reference Manual_ by Harbison and Steele, an old C book I have on my shelf. They use these names (in the index only):
+= assign sum
-= assign difference
*= assign product
/= assign quotient
That would lead to traits names like these:
can_assign_sum
can_assign_difference
can_assign_product
can_assign_quotient
TCPL uses the following names:
+= add and assign
-= subtract and assign
*= multiply and assign
/= divide and assign
That leads, of course to names like these:
can_add_and_assign
can_subtract_and_assign
can_multiply_and_assign
can_divide_and_assign
Those names don't match the concept names, as Joachim suggested, but they read well.
_____
Rob Stewart robert.stewart_at_[hidden]
Software Engineer using std::disclaimer;
Dev Tools & Components
Susquehanna International Group, LLP http://www.sig.com
IMPORTANT: The information contained in this email and/or its attachments is confidential. If you are not the intended recipient, please notify the sender immediately by reply and immediately delete this message and all its attachments. Any review, use, reproduction, disclosure or dissemination of this message or any attachment by an unintended recipient is strictly prohibited. Neither this message nor any attachment is intended as or should be construed as an offer, solicitation or recommendation to buy or sell any security or other financial instrument. Neither the sender, his or her employer nor any of their respective affiliates makes any warranties as to the completeness or accuracy of any of the information contained herein or that this message or any of its attachments is free of viruses.
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk