Marshall Clow
71e699dda5
Fix for PR17606 - result_of (and INVOKE) works incorrectly for member function pointers with ref qualifiers. Also a drive-by fix for common_type in C++03 mode. Thanks to Michel Morin for the bug report and the proposed fix.
...
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@201101 91177308-0d34-0410-b5e6-96231b3b80d8
2014-02-10 17:40:28 +00:00
Marshall Clow
ebfc50ee89
Fix for PR18735 - self-assignment for map/multimap gives incorrect results in C++03
...
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@201021 91177308-0d34-0410-b5e6-96231b3b80d8
2014-02-08 04:03:14 +00:00
Joerg Sonnenberger
cf7278afd7
Avoid signed vs unsigned compare warnings. From Dimitry Andric.
...
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@200993 91177308-0d34-0410-b5e6-96231b3b80d8
2014-02-07 21:14:29 +00:00
Peter Collingbourne
a3dc8f3b8b
Support forward_list<Incomplete Type>. Patch by Zhihao Yuan!
...
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@200814 91177308-0d34-0410-b5e6-96231b3b80d8
2014-02-05 01:44:17 +00:00
Howard Hinnant
08356fbee7
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.
...
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@200793 91177308-0d34-0410-b5e6-96231b3b80d8
2014-02-04 19:51:48 +00:00
Marshall Clow
13fbe9d5e3
Fix numeric.limits.members/traps.pass.cpp to pass on non-x86 architectures. Fixes bug #18468
...
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@200724 91177308-0d34-0410-b5e6-96231b3b80d8
2014-02-03 23:26:56 +00:00
Logan Chien
e1678a18d9
Remove default function template argument from the header.
...
GCC will treat the default function template arguments as a
compilation error if C++0x is not enabled.
This commit workaround the compilation error by moving the
SFINAE check to function argument instead of the template
argument.
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@200523 91177308-0d34-0410-b5e6-96231b3b80d8
2014-01-31 09:30:46 +00:00
David Fang
a612c62740
lit.site.cfg:cxx_under_test should take precedence over 'which clang++'
...
(reviewed by Marshall Clow)
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@200364 91177308-0d34-0410-b5e6-96231b3b80d8
2014-01-29 01:54:52 +00:00
Marshall Clow
28754d0378
Removed extra line that I left in when committing 199694. Thanks to Jared Grubb for the catch.
...
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@200108 91177308-0d34-0410-b5e6-96231b3b80d8
2014-01-26 01:59:59 +00:00
Marshall Clow
708dd84a4e
Rename some internal templates to avoid conflict with complier intrinsics. __is_constructible --> __libcpp_is_constructible, __is_nothrow_constructible --> __libcpp_is_nothrow_constructible, and __is_nothrow_assignable --> __libcpp_is_nothrow_assignable. No functionality change.
...
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@200010 91177308-0d34-0410-b5e6-96231b3b80d8
2014-01-24 15:27:41 +00:00
Peter Collingbourne
a4c0d87a84
Const qualify __mem_fn call operator
...
QOI improvement.
Differential Revision: http://llvm-reviews.chandlerc.com/D2059
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@199848 91177308-0d34-0410-b5e6-96231b3b80d8
2014-01-22 22:56:52 +00:00
Marshall Clow
15066f21f1
Removed extra space; thanks to thakis_'s eagle eye
...
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@199695 91177308-0d34-0410-b5e6-96231b3b80d8
2014-01-21 00:03:44 +00:00
Marshall Clow
1a383b9755
Fixed test failure in is_iec559.pass.cpp on darwin-ppc32. Thanks to David Fang for the report (and suggested fix)
...
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@199694 91177308-0d34-0410-b5e6-96231b3b80d8
2014-01-20 23:57:16 +00:00
Marshall Clow
e3c9d52d6d
Fix erroneous test; was failing on darwin-ppc32. Fixes PR18469.
...
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@199542 91177308-0d34-0410-b5e6-96231b3b80d8
2014-01-18 03:41:54 +00:00
Marshall Clow
97f50f6c5e
Update __parse_DUP_COUNT and __parse_BACKREF to use the traits class to recognize digits. Fixes PR18514
...
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@199541 91177308-0d34-0410-b5e6-96231b3b80d8
2014-01-18 03:40:03 +00:00
Alp Toker
63fbfd6883
Adjust build fix from r199494 to use C++ casts
...
Change suggested by Joerg Sonnenberger!
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@199500 91177308-0d34-0410-b5e6-96231b3b80d8
2014-01-17 16:17:24 +00:00
Alp Toker
5f58b89ecd
Build fix for gcc builtin
...
The __sync_add_and_fetch() builtin parameter is volatile but clang has
'different' type checking and ends up accepting this code.
Undo the C++ cast from r198505 to get libc++/LLVM building with g++ while this
is investigated.
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@199494 91177308-0d34-0410-b5e6-96231b3b80d8
2014-01-17 14:24:23 +00:00
Marshall Clow
98760c18f8
Add license headers to a bunch of libc++ files that were missing them. No functionality change. Fixes 18291. Thanks to Nico for the bug report and the patch.
...
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@199400 91177308-0d34-0410-b5e6-96231b3b80d8
2014-01-16 16:58:45 +00:00
Marshall Clow
beee5e48b3
Apply patch for Albert Wong: 'Modify testit to allow filtering tests by prefixes'.
...
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@199318 91177308-0d34-0410-b5e6-96231b3b80d8
2014-01-15 16:28:42 +00:00
Marshall Clow
928bb68bb2
Whoops! Set the default in the last commit to c++1y instead of c++11
...
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@199224 91177308-0d34-0410-b5e6-96231b3b80d8
2014-01-14 17:04:06 +00:00
Marshall Clow
2f78c0d9f9
Update lib/buildit and test/testit to both pay attention to an env flag CXX_LANG, which people can set to 'c++03', 'c++11' or 'c++1y' to build/test using that language variant. If you don't set this env variable, you get c++11, just like today. Drive-by fix; remove duplicate -nostdinc++.
...
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@199222 91177308-0d34-0410-b5e6-96231b3b80d8
2014-01-14 17:00:40 +00:00
Marshall Clow
8896ac3cdd
Rename libc++ internal templates __is_void, __is_integral, __is_floating_point, __is_pointer, __is_function_imp, __is_function, __is_member_function_pointer, __is_member_pointer, __is_signed_impl, __is_signed, __is_unsigned_impl, __is_unsigned to __libcpp_is_XXX, because some compilers have decided that __is_XXX are keywords. No functionality change.
...
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@199184 91177308-0d34-0410-b5e6-96231b3b80d8
2014-01-14 05:13:45 +00:00
Marshall Clow
72fe0ae7cf
Fix a bug in regex_token_iterator's copy constructor. Caught by Bob Wilson.
...
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@199122 91177308-0d34-0410-b5e6-96231b3b80d8
2014-01-13 17:47:08 +00:00
Marshall Clow
0efd9dcfa0
Fix PR18404 - 'Bug in regex_token_iterator::operator++(int) implementation'. Enhance the tests for regex_token_iterator and regex_iterator.
...
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@198878 91177308-0d34-0410-b5e6-96231b3b80d8
2014-01-09 18:25:57 +00:00
Joerg Sonnenberger
4a07e0e159
Replace casts of __impl_ with the correct reinterpret_cast of the
...
address. Restores the assembly of before r198504.
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@198698 91177308-0d34-0410-b5e6-96231b3b80d8
2014-01-07 19:21:13 +00:00
Marshall Clow
908b5d7f92
Back out the <type_traits> changes from r198431; they were breaking when building with glibc. Need to find a better solution for PR18218.
...
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@198623 91177308-0d34-0410-b5e6-96231b3b80d8
2014-01-06 18:12:50 +00:00
Marshall Clow
af6cd294aa
Removed extra trailing underscore in #ifdef (__GNUC___ --> __GNUC__ )
...
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@198618 91177308-0d34-0410-b5e6-96231b3b80d8
2014-01-06 15:23:02 +00:00
Marshall Clow
0ea7f8cfb3
Rename several internal templates to get rid of ___ (triple underscores) or worse, four. No functionality change.
...
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@198608 91177308-0d34-0410-b5e6-96231b3b80d8
2014-01-06 14:00:09 +00:00
Joerg Sonnenberger
4c6acb5ecd
Switch to using C++ style casts.
...
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@198505 91177308-0d34-0410-b5e6-96231b3b80d8
2014-01-04 17:43:00 +00:00
Yaron Keren
6c27250223
80 cols fixes.
...
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@198482 91177308-0d34-0410-b5e6-96231b3b80d8
2014-01-04 09:27:39 +00:00
Yaron Keren
c8d1bbab02
Implement the functions: clz, clzl, clzll, ctz, ctzl, and ctzll
...
for libcxx when compiled with Visual C++ on Win32 and Win64.
clang and gcc (MinGW) compilers provide these implementations themselves.
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@198481 91177308-0d34-0410-b5e6-96231b3b80d8
2014-01-04 08:56:00 +00:00
Marshall Clow
a71f9562f0
Rename ___make_pair_return to __make_pair_return_impl; ___make_tuple_return to __make_tuple_return_impl; and ____iterator_traits to __iterator_traits_impl. Part of a campaign to remove > 2 underscores from libc++. No functionality change.
...
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@198457 91177308-0d34-0410-b5e6-96231b3b80d8
2014-01-03 22:55:49 +00:00
Marshall Clow
854a7a02b4
Patch by Howard. First part of fix for PR18218; add type traits needed to do the right thing. Fix the problems in PR18218 for isnan and pow - they also need to be applied to the other functions in <cmath>. Also, a drive-by fix for the test - now actually calls test_abs()
...
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@198431 91177308-0d34-0410-b5e6-96231b3b80d8
2014-01-03 18:21:14 +00:00
NAKAMURA Takumi
3f44c407b6
Update the copyright credits -- Happy new year 2014!
...
FIXME: Dragonegg may be updated at non-trivial changes.
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@198274 91177308-0d34-0410-b5e6-96231b3b80d8
2014-01-01 08:27:31 +00:00
Marshall Clow
239bc42b53
Make cv_status a class enum. Fixes PR18314. Thanks to Andersca for the report and the patch.
...
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@197921 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-23 22:14:27 +00:00
Yaron Keren
f1ebe26bdb
Empty line between two unrelated #ifdefs.
...
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@197810 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-20 13:19:45 +00:00
Logan Chien
8f48c23568
Fix GCC unknown pragma warning in libc++.
...
We should check defined(__clang__) before the usage of the
clang diagnostic pragmas.
The [-Wswitch] warning in src/future.cpp should be ignored.
As the result, the equivalent GCC pragma is added.
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@197314 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-14 06:45:09 +00:00
Logan Chien
bfd68bf0c7
GCC does not support strong enum in pre-C++0x mode.
...
GCC does not support strong enum if -std=c++0x is not used.
Without the strong enum, we will see following error:
In file included from libcxx/include/ostream:131:0,
from libcxx/include/sstream:174,
from libcxx/include/complex:247,
from cpp03-headers.cpp:11:
libcxx/include/ios:419:68: error: 'io_errc' is not a class or namespace
libcxx/include/ios:420:66: error: 'io_errc' is not a class or namespace
To workaround this issue, this commit will define
_LIBCPP_HAS_NO_STRONG_ENUMS when we are compiling with
g++ without c++0x.
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@197313 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-14 06:44:09 +00:00
Marshall Clow
1c398696b0
Move std::begin(array) and std::end(array) out from under an #ifdef that was preventing people from building libc++ using gcc. This corrects a mistake that I introduced in r196058
...
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@197061 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-11 19:32:32 +00:00
Marshall Clow
73b46a7248
Refactored a bunch of duplicated code in <ostream>. Made a new routine called __put_character_sequence, and made nine places call it.
...
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@196951 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-10 19:25:49 +00:00
Marshall Clow
b671fc9b2d
Refactor some of the operations in <string> so that they can be reused; no functionality change
...
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@196788 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-09 16:00:28 +00:00
Howard Hinnant
615100223e
Give all members of exception types default visibility. Lack of this is causing some illegal code relocations rare and hard to reproduce cases.
...
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@196411 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-04 21:03:23 +00:00
Marshall Clow
1b92188a82
Found six (nmostly) identical files named 'test_allocator.h' in the libcxx test suite. Moved one to /support, made it a superset, and removed all but one of the others, and iupdated all the includes. Left the odd one (thread/futures/test_allocator.h) for later.
...
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@196174 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-03 00:18:10 +00:00
Marshall Clow
ebedffde9a
Found two identical files named 'allocators.h' in the libcxx test suite. Moved one to /support, removed the other, and iupdated all the includes. No functionality change
...
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@196127 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-02 18:08:31 +00:00
Marshall Clow
e27dbcf2dc
Found two identical files named 'DefaultOnly.h' in the libcxx test suite. Moved one to /support, removed the other, and iupdated all the includes. No functionality change
...
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@196118 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-02 17:00:56 +00:00
Marshall Clow
6daf534441
Fix for PRPR17934; based on a fix suggested by Peter Sommerlad
...
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@196058 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-02 03:24:33 +00:00
Sylvestre Ledru
a7d46056b0
Remove executable permissions on a text file
...
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@196041 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-01 10:15:11 +00:00
Howard Hinnant
92b327712b
Remove _LIBCPP_TRIVIAL_PAIR_COPY_CTOR=0 for __APPLE__, no longer needed.
...
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@195796 91177308-0d34-0410-b5e6-96231b3b80d8
2013-11-27 00:53:02 +00:00
Marshall Clow
061d0cc4db
There were two identical files named 'min_allocator.h'. Move one of them to /support and delete the other. Then adjust all the tests that used them to include the moved one. No functionality change.
...
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@195785 91177308-0d34-0410-b5e6-96231b3b80d8
2013-11-26 20:58:02 +00:00
Joerg Sonnenberger
bfaafd539c
Don't use T as template argument, it is part of the application
...
namespace.
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@195693 91177308-0d34-0410-b5e6-96231b3b80d8
2013-11-25 22:44:20 +00:00