|
Boost : |
Subject: Re: [boost] static in_class constants
From: Herve Bronnimann (hervebronnimann_at_[hidden])
Date: 2010-03-15 12:24:01
Someone is bound to reply this sooner or later so I thought I might:
it's a bad idea because of (see below). Boost convention uses m_
prefix for members. Cheers, HB
From the 2003 C++ Standard:
17.4.3.2.1 Global names [lib.global.names]
Certain sets of names and function signatures are always reserved to
the implementation:
Each name that contains a double underscore (_ _) or begins with an
underscore followed by an uppercase letter (2.11) is reserved to the
implementation for any use.
Each name that begins with an underscore is reserved to the
implementation for use as a name in the global namespace.165
165) Such names are also reserved in namespace ::std (17.4.3.1).
Sent from my iPhone
On Mar 15, 2010, at 11:06 AM, Christian Henning <chhenning_at_[hidden]>
wrote:
> Hi Mateusz,
>
>>
>> I have question of different nature, why the names are
>> prefixed with underscore? Does it denote they are private,
>> as implementation detail, shouldn't be used as part of public
>> interface, any other purpose?
>>
>
> It's my coding style to have members ( public, protected, private )
> marked with an underscore. I believe it enhances readability. But that
> might be just me.
>
> Regards,
> Christian
> _______________________________________________
> Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk