Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
Message from discussion Initialization and trivial constructors
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
Martin B.  
View profile  
 More options Apr 26 2012, 5:17 pm
Newsgroups: comp.lang.c++.moderated
From: "Martin B." <0xCDCDC...@gmx.at>
Date: Thu, 26 Apr 2012 14:17:54 -0700 (PDT)
Local: Thurs, Apr 26 2012 5:17 pm
Subject: Re: Initialization and trivial constructors
On 25.04.2012 20:31, Miles Bader wrote:

> Gene Bushuyev<publicfil...@gbresearch.com>  writes:
>> What you're describing is this: your class needs to create another
>> complex or costly object, which it then uses as an organ donor to
>> initialize (or assign) its own members. Perhaps, if the class
>> contained that complex or costly object instead of its organs would
>> be a better design and made this procedure unnecessary.

> Certainly one way (...) it's a workaround, not "better design."

> If the intermediate value is small / doesn't consume too many
> resources, then whatever, maybe it's an _acceptable_ workaround, but
> it's still a workaround.

> [E.g., (...)]

Miles - maybe you could dig up one concrete example from your code base?
Would help to show what you mean ...

cheers,
Martin

--
Good C++ code is better than good C code, but
bad C++ can be much, much worse than bad C code.

      [ See http://www.gotw.ca/resources/clcm.htm for info about ]
      [ comp.lang.c++.moderated.    First time posters: Do this! ]


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.