This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug libstdc++/59680] New: Compile error in thread.cc
- From: "rbmj at verizon dot net" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Sun, 05 Jan 2014 03:12:16 +0000
- Subject: [Bug libstdc++/59680] New: Compile error in thread.cc
- Auto-submitted: auto-generated
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=59680
Bug ID: 59680
Summary: Compile error in thread.cc
Product: gcc
Version: 4.9.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: libstdc++
Assignee: unassigned at gcc dot gnu.org
Reporter: rbmj at verizon dot net
Line 186 of thread.cc:
::sleep(__s.count() + (__ns >= 1000000));
There are two issues with this:
1) Semantically, it doesn't make sense that there would only be 6 zeros after
anything dealing with nano, since nano is *10^-9.
2) This is a compilation error. ns is std::chrono::duration, and gcc can't
find a >= for integral constants. I believe this is should be a /, but it
could conceivably intend for the boolean result to be implicitly converted into
a 1 (this seems strange though)
This is present in both 4.8.2 and trunk