Boost logo

Boost :

Subject: Re: [boost] [Boost-users] [Review] Type Traits Extension by Frederic Bron - Review summary and decision
From: Stewart, Robert (Robert.Stewart_at_[hidden])
Date: 2011-03-28 09:05:25


Joachim Faulhaber wrote:
> 2011/3/28 Stewart, Robert <Robert.Stewart_at_[hidden]>:
> > Joachim Faulhaber wrote:
> >> 2011/3/27 Frédéric Bron <frederic.bron_at_[hidden]>:
> >> >
> >> > What about is_callable_plus, is_callable_plus_assign, ...
> >> > i.e. is_callable_xxxx where xxxx the same as in Boost.Proto?
> >> >
> >> > I know that is_xxxx_callable reads better but I like to have
> >> > a common prefix longer than is_.
> >>
> > is_callable_add/is_callable_addition/is_callable_plus isn't
> > much better
> >
> > "can_call_" seems to be a nice, reasonably short prefix:
> > can_call_addition, can_call_equal_to, can_call_bitwise_xor,
> > can_call_left_shift, etc.
>
> These naming debates tend to become a little tiring. Given the names
> that have been chosen in the standard and other boost libraries and a
> simple and uniform semantics of these operator traits I would prefer a
> naming that is simple and uniform as well.

OK, but I didn't think I was suggesting otherwise.

> As I stated in my review already I can live with a simple
>
> has_xxxx
> where xxxx
>
> are most unifying names as proposed in
> https://svn.boost.org/trac/boost/wiki/Guidelines/Naming/Operators

I know that, but there is wiggle room yet in what goes in your MUP column and I was proposing "can_call_" as a shorter version of Frédéric's "is_callable_" idea that reads better and is shorter. Since he raised the question, he apparently hasn't accepted your "has_" prefix suggestion yet and is still fishing for ideas.

_____
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