[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re[2]: Input copy ctor (was: [lmi] wxmsw-2.9.0 regression: messagebox do
From: |
Vadim Zeitlin |
Subject: |
Re[2]: Input copy ctor (was: [lmi] wxmsw-2.9.0 regression: messagebox doubling) |
Date: |
Thu, 26 Feb 2009 15:02:25 +0100 |
On Thu, 26 Feb 2009 13:23:44 +0000 Greg Chicares <address@hidden> wrote:
GC> On 2009-02-26 12:55Z, Vadim Zeitlin wrote:
GC> > Just in case it can help, here is the sequence of messages I get after
GC> > applying this patch:
GC> >
GC> > ---------------------------
GC> > 55 is CurrentCoiMultiplierRealized_.size()
GC> > 55 is years_to_maturity()
GC> > 45 is issue_age ()
GC> > 65 is retirement_age ()
GC> > 0 is inforce_year ()
GC> > 2009 is effective_year ()
GC>
GC> That seems uninteresting, as I expected it to be.
GC>
GC> > [file .\input_realization.cpp, line 440]
GC> > ---------------------------
GC> >
GC> > 0 is z.CurrentCoiMultiplierRealized_.size()
GC> > 0 is CurrentCoiMultiplier.size()
GC>
GC> Here I have 55 for both sizes. I believe this is where it goes wrong.
GC> I will scrutinize this now.
I see that Input class copy ctor doesn't work in my (MSVC) version. I.e.
what happens is that Input::magically_rectify() correctly sets up
CurrentCoiMultiplierRealized_ but the copy created when it returns -- and
hence the object which is passed to BasicValues ctor when it's called from
AccountValue ctor -- has this value as empty vector.
Unfortunately I don't understand the code in (and called from) Input copy
ctor enough to understand whether it's a compiler bug or not. Right now I
just don't see where is CurrentCoiMultiplierRealized_ copied there,
AscribeMembers() only seems to deal with CurrentCoiMultiplier_ value but
not the "Realized" vector. What am I missing here?
Or could it be that g++ applies the RVO here and doesn't use this copy
ctor at all (while MSVC definitely doesn't apply it in debug builds, which
is what I use)?
Thanks,
VZ
- Re: [lmi] wxmsw-2.9.0 regression: messagebox doubling, (continued)
- Re: [lmi] wxmsw-2.9.0 regression: messagebox doubling, Vadim Zeitlin, 2009/02/24
- Re: [lmi] wxmsw-2.9.0 regression: messagebox doubling, Greg Chicares, 2009/02/24
- Re[2]: [lmi] wxmsw-2.9.0 regression: messagebox doubling, Vadim Zeitlin, 2009/02/24
- Message not available
- Re: [lmi] wxmsw-2.9.0 regression: messagebox doubling, Greg Chicares, 2009/02/24
- Re[2]: [lmi] wxmsw-2.9.0 regression: messagebox doubling, Vadim Zeitlin, 2009/02/25
- Re: [lmi] wxmsw-2.9.0 regression: messagebox doubling, Greg Chicares, 2009/02/26
- Re[2]: [lmi] wxmsw-2.9.0 regression: messagebox doubling, Vadim Zeitlin, 2009/02/26
- Re: [lmi] wxmsw-2.9.0 regression: messagebox doubling, Greg Chicares, 2009/02/26
- Re: [lmi] wxmsw-2.9.0 regression: messagebox doubling, Greg Chicares, 2009/02/26
- Re[2]: [lmi] wxmsw-2.9.0 regression: messagebox doubling, Vadim Zeitlin, 2009/02/26
- Re[2]: Input copy ctor (was: [lmi] wxmsw-2.9.0 regression: messagebox doubling),
Vadim Zeitlin <=
- [lmi] Re: Input copy ctor, Greg Chicares, 2009/02/26
- Re: [lmi] Re: Input copy ctor, Vadim Zeitlin, 2009/02/26
- Re: [lmi] Re: Input copy ctor, Greg Chicares, 2009/02/26
- Re[2]: [lmi] Re: Input copy ctor, Vadim Zeitlin, 2009/02/26
- Re: [lmi] Re: Input copy ctor, Greg Chicares, 2009/02/26
Re: [lmi] wxmsw-2.9.0 regression: messagebox doubling, Vadim Zeitlin, 2009/02/26