[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [lmi] Build warnings for pre-wx-2.9.5
From: |
Greg Chicares |
Subject: |
Re: [lmi] Build warnings for pre-wx-2.9.5 |
Date: |
Sat, 18 Oct 2014 21:31:13 +0000 |
User-agent: |
Mozilla/5.0 (Windows NT 5.1; rv:24.0) Gecko/20100101 Thunderbird/24.6.0 |
On 2013-07-12 14:13Z, Vadim Zeitlin wrote:
> On Fri, 12 Jul 2013 13:05:34 +0000 Greg Chicares <address@hidden> wrote:
[...]
> GC> ../src/common/docview.cpp: In member function `virtual wxDocument*
> wxDocManager::CreateDocument(const wxString&, long int)':
> GC> ../src/common/docview.cpp:1504: warning: 'docNew' might be used
> uninitialized in this function
>
> We had already discussed it in the past and it seems to be impossible to
> avoid it as it's really due to a compiler bug (if you look at the sources,
> you can see that the variable is initialized when it's declared so there is
> no chance whatsoever for it to be used uninitialized).
Unsurprisingly, it's still there when I use the same old compiler to build
a wx snapshot as of 2014-10-18T16:40Z. Now I see one more warning that is
similar, on similar code:
../src/common/event.cpp: In member function `bool
wxEvtHandler::SafelyProcessEvent(wxEvent&)':
../src/common/event.cpp:1618: warning: 'loop' might be used uninitialized in
this function
1618 wxEventLoopBase * const loop = wxEventLoopBase::GetActive();
../src/common/docview.cpp: In member function `virtual wxDocument*
wxDocManager::CreateDocument(const wxString&, long int)':
../src/common/docview.cpp:1516: warning: 'docNew' might be used uninitialized
in this function
1516 wxDocument * const docNew = temp->CreateDocument(path, flags);
I don't see how, in code like this:
T* const t = initializer();
't' could actually be used uninitialized: the warning does seem erroneous,
and I agree that we should dismiss it as a compiler defect.
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- Re: [lmi] Build warnings for pre-wx-2.9.5,
Greg Chicares <=