[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-devel
Subject:    Re: Philosophical question
From:       Thiago Macieira <thiago () kde ! org>
Date:       2006-11-17 15:20:12
Message-ID: 200611171620.22598.thiago () kde ! org
[Download RAW message or body]

[Attachment #2 (multipart/signed)]


Remi Villatel wrote:
>Now, what are the differences in between
>
>QSomeThing anotherOne = thatThing;
>
>and
>
>QSomeThing anotherOne(thatThing);
>
>?

In most compilers, none. But some compilers (including gcc with the 
appropriate option) will generate a call to the default constructor on 
the first one unnecessarily.

>I haven't tested to switch entirely to one way or to the other, so I
> wonder what the pros and cons are. I'm especially interested in the
> speed related consequences for my style.

If you haven't tested, why are you posting? Test first, then post your 
conclusions.

-- 
  Thiago Macieira  -  thiago (AT) macieira.info - thiago (AT) kde.org
    PGP/GPG: 0x6EF45358; fingerprint:
    E067 918B B660 DBD1 105C  966C 33F5 F005 6EF4 5358

[Attachment #5 (application/pgp-signature)]

>> Visit http://mail.kde.org/mailman/listinfo/kde-devel#unsub to unsubscribe <<


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic