lmi
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [lmi] [lmi-commits] master 8862ffc 7/9: Improve const correctness


From: Vadim Zeitlin
Subject: Re: [lmi] [lmi-commits] master 8862ffc 7/9: Improve const correctness
Date: Thu, 13 Jun 2019 02:40:29 +0200

On Thu, 13 Jun 2019 00:00:48 +0000 Greg Chicares <address@hidden> wrote:

GC> On 2019-06-12 17:26, Vadim Zeitlin wrote:
GC> > On Wed, 12 Jun 2019 12:53:00 -0400 (EDT) Greg Chicares <address@hidden> 
wrote:
GC> [...]
GC> > GC> commit 8862ffce33cd76fb09a5a5850d058a3807be9a17
GC> [...] 
GC> > GC>     Improve const correctness
GC> > GC>     
GC> > GC>     Replaced this idiom:
GC> > GC>       https://isocpp.org/wiki/faq/ctors#named-parameter-idiom
GC> > GC>     with a const variant that suffices for all real-world use cases.
GC> [...]
GC> >  These const methods indeed seem to be sufficient, but for someone used to
GC> > the named parameter idiom use (such as me), they look quite confusing. I
GC> 
GC> I hadn't remembered it as a standard idiom until I searched for it.
GC> 
GC> I've added some comments reflecting your suggestions.

 Thanks, this definitely helps.

GC> The lines exceed eighty characters, so they're too long already.
[...]
GC> This thing is regrettably metastable, but I can't think of a good way
GC> to change it again without making it worse.

 The only suggestion I have here is to implement them outside of the class,
on multiple lines. I guess you don't want to have multiple lines inside the
class declaration because it would make the class synopsis less obvious,
but this consideration doesn't apply if you put them outside of it, does
it?

 Regards,
VZ

Attachment: pgpdev3CkjbbC.pgp
Description: PGP signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]