public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/56762] New: too aggressive optimization or missing warnings
@ 2013-03-28 10:37 npl at chello dot at
  2013-03-28 12:15 ` [Bug c++/56762] " daniel.kruegler at googlemail dot com
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: npl at chello dot at @ 2013-03-28 10:37 UTC (permalink / raw)
  To: gcc-bugs


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=56762

             Bug #: 56762
           Summary: too aggressive optimization or missing warnings
    Classification: Unclassified
           Product: gcc
           Version: 4.7.2
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: npl@chello.at


Created attachment 29743
  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=29743
code describing the issue

Alternatively this could be just me misunderstanding C++.
But the issue is that I have an object created on the stack and I would expect
it to survive until it goes out of scope.
Now I understand that I probably used it the wrong way by giving it a temporary
when it needed a reference to something more solid, but I would expect an error
message in this case.

Please look at the provided code, which compiles without error/warning. the
exchange function wont have any calls to lock/unlock.

tested with gcc 4.7.2 + 4.8.0


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2013-03-28 15:14 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-03-28 10:37 [Bug c++/56762] New: too aggressive optimization or missing warnings npl at chello dot at
2013-03-28 12:15 ` [Bug c++/56762] " daniel.kruegler at googlemail dot com
2013-03-28 13:38 ` npl at chello dot at
2013-03-28 15:14 ` redi at gcc dot gnu.org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).