[libcxx] r200793 - Albert Wong: Fix thread.thread.id/lt.pass.cpp to not assume thread::id() produces a minimal value. This enables this test to pass on andriod arm.
Howard Hinnant
hhinnant at apple.com
Tue Feb 4 11:51:49 PST 2014
Author: hhinnant
Date: Tue Feb 4 13:51:48 2014
New Revision: 200793
URL: http://llvm.org/viewvc/llvm-project?rev=200793&view=rev
Log:
Albert Wong: Fix thread.thread.id/lt.pass.cpp to not assume thread::id() produces a minimal value. This enables this test to pass on andriod arm.
Modified:
libcxx/trunk/test/thread/thread.threads/thread.thread.class/thread.thread.id/lt.pass.cpp
Modified: libcxx/trunk/test/thread/thread.threads/thread.thread.class/thread.thread.id/lt.pass.cpp
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/thread/thread.threads/thread.thread.class/thread.thread.id/lt.pass.cpp?rev=200793&r1=200792&r2=200793&view=diff
==============================================================================
--- libcxx/trunk/test/thread/thread.threads/thread.thread.class/thread.thread.id/lt.pass.cpp (original)
+++ libcxx/trunk/test/thread/thread.threads/thread.thread.class/thread.thread.id/lt.pass.cpp Tue Feb 4 13:51:48 2014
@@ -28,8 +28,14 @@ int main()
assert( (id0 <= id1));
assert(!(id0 > id1));
assert( (id0 >= id1));
- assert( (id0 < id2));
- assert( (id0 <= id2));
- assert(!(id0 > id2));
- assert(!(id0 >= id2));
+ assert(!(id0 == id2));
+ if (id0 < id2) {
+ assert( (id0 <= id2));
+ assert(!(id0 > id2));
+ assert(!(id0 >= id2));
+ } else {
+ assert(!(id0 <= id2));
+ assert( (id0 > id2));
+ assert( (id0 >= id2));
+ }
}
More information about the cfe-commits
mailing list