Commit Graph

1313 Commits

Author SHA1 Message Date
David Fang 7584238232 lit.site.cfg:cxx_under_test should take precedence over 'which clang++'
(reviewed by Marshall Clow)

llvm-svn: 200364
2014-01-29 01:54:52 +00:00
Marshall Clow 30f1883eee Removed extra line that I left in when committing 199694. Thanks to Jared Grubb for the catch.
llvm-svn: 200108
2014-01-26 01:59:59 +00:00
Marshall Clow f246033698 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.
llvm-svn: 200010
2014-01-24 15:27:41 +00:00
Peter Collingbourne a5adf489b7 Const qualify __mem_fn call operator
QOI improvement.

Differential Revision: http://llvm-reviews.chandlerc.com/D2059

llvm-svn: 199848
2014-01-22 22:56:52 +00:00
Marshall Clow d724d60fff Removed extra space; thanks to thakis_'s eagle eye
llvm-svn: 199695
2014-01-21 00:03:44 +00:00
Marshall Clow 683268b2d8 Fixed test failure in is_iec559.pass.cpp on darwin-ppc32. Thanks to David Fang for the report (and suggested fix)
llvm-svn: 199694
2014-01-20 23:57:16 +00:00
Marshall Clow 7132122196 Fix erroneous test; was failing on darwin-ppc32. Fixes PR18469.
llvm-svn: 199542
2014-01-18 03:41:54 +00:00
Marshall Clow 9aafa898f9 Update __parse_DUP_COUNT and __parse_BACKREF to use the traits class to recognize digits. Fixes PR18514
llvm-svn: 199541
2014-01-18 03:40:03 +00:00
Alp Toker 5fea974b6b Adjust build fix from r199494 to use C++ casts
Change suggested by Joerg Sonnenberger!

llvm-svn: 199500
2014-01-17 16:17:24 +00:00
Alp Toker 0b438a9f63 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.

llvm-svn: 199494
2014-01-17 14:24:23 +00:00
Marshall Clow 354d39cabc 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.
llvm-svn: 199400
2014-01-16 16:58:45 +00:00
Marshall Clow 9f4be3fa4f Apply patch for Albert Wong: 'Modify testit to allow filtering tests by prefixes'.
llvm-svn: 199318
2014-01-15 16:28:42 +00:00
Marshall Clow b183f8594f Whoops! Set the default in the last commit to c++1y instead of c++11
llvm-svn: 199224
2014-01-14 17:04:06 +00:00
Marshall Clow 4cdc6feb4f 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++.
llvm-svn: 199222
2014-01-14 17:00:40 +00:00
Marshall Clow ec931c0721 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.
llvm-svn: 199184
2014-01-14 05:13:45 +00:00
Marshall Clow 54f6bd59f5 Fix a bug in regex_token_iterator's copy constructor. Caught by Bob Wilson.
llvm-svn: 199122
2014-01-13 17:47:08 +00:00
Marshall Clow 79b0fee3c6 Fix PR18404 - 'Bug in regex_token_iterator::operator++(int) implementation'. Enhance the tests for regex_token_iterator and regex_iterator.
llvm-svn: 198878
2014-01-09 18:25:57 +00:00
Joerg Sonnenberger 70d4ba7f19 Replace casts of __impl_ with the correct reinterpret_cast of the
address. Restores the assembly of before r198504.

llvm-svn: 198698
2014-01-07 19:21:13 +00:00
Marshall Clow a429ba738c Back out the <type_traits> changes from r198431; they were breaking when building with glibc. Need to find a better solution for PR18218.
llvm-svn: 198623
2014-01-06 18:12:50 +00:00
Marshall Clow a889636aa0 Removed extra trailing underscore in #ifdef (__GNUC___ --> __GNUC__ )
llvm-svn: 198618
2014-01-06 15:23:02 +00:00
Marshall Clow a3e6e2b286 Rename several internal templates to get rid of ___ (triple underscores) or worse, four. No functionality change.
llvm-svn: 198608
2014-01-06 14:00:09 +00:00
Joerg Sonnenberger 634b9dd768 Switch to using C++ style casts.
llvm-svn: 198505
2014-01-04 17:43:00 +00:00
Yaron Keren acb42aefd7 80 cols fixes.
llvm-svn: 198482
2014-01-04 09:27:39 +00:00
Yaron Keren f8f56755e0 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.

llvm-svn: 198481
2014-01-04 08:56:00 +00:00
Marshall Clow 0724bf6767 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.
llvm-svn: 198457
2014-01-03 22:55:49 +00:00
Marshall Clow d41295da72 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()
llvm-svn: 198431
2014-01-03 18:21:14 +00:00
NAKAMURA Takumi d40d387fb1 Update the copyright credits -- Happy new year 2014!
FIXME: Dragonegg may be updated at non-trivial changes.
llvm-svn: 198274
2014-01-01 08:27:31 +00:00
Marshall Clow ce81aed463 Make cv_status a class enum. Fixes PR18314. Thanks to Andersca for the report and the patch.
llvm-svn: 197921
2013-12-23 22:14:27 +00:00
Yaron Keren 21a697b8b1 Empty line between two unrelated #ifdefs.
llvm-svn: 197810
2013-12-20 13:19:45 +00:00
Logan Chien b0d5be563b 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.

llvm-svn: 197314
2013-12-14 06:45:09 +00:00
Logan Chien ca83921ddc 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.

llvm-svn: 197313
2013-12-14 06:44:09 +00:00
Marshall Clow c66a611b27 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
llvm-svn: 197061
2013-12-11 19:32:32 +00:00
Marshall Clow 6bc32ebf35 Refactored a bunch of duplicated code in <ostream>. Made a new routine called __put_character_sequence, and made nine places call it.
llvm-svn: 196951
2013-12-10 19:25:49 +00:00
Marshall Clow 8283ba3704 Refactor some of the operations in <string> so that they can be reused; no functionality change
llvm-svn: 196788
2013-12-09 16:00:28 +00:00
Howard Hinnant 395485efc0 Give all members of exception types default visibility. Lack of this is causing some illegal code relocations rare and hard to reproduce cases.
llvm-svn: 196411
2013-12-04 21:03:23 +00:00
Marshall Clow c3deeb5f89 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.
llvm-svn: 196174
2013-12-03 00:18:10 +00:00
Marshall Clow e7d582a75c 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
llvm-svn: 196127
2013-12-02 18:08:31 +00:00
Marshall Clow a26fcc7989 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
llvm-svn: 196118
2013-12-02 17:00:56 +00:00
Marshall Clow 3772a46ab4 Fix for PRPR17934; based on a fix suggested by Peter Sommerlad
llvm-svn: 196058
2013-12-02 03:24:33 +00:00
Sylvestre Ledru 3973d59f9b Remove executable permissions on a text file
llvm-svn: 196041
2013-12-01 10:15:11 +00:00
Howard Hinnant 6ef2bb02f5 Remove _LIBCPP_TRIVIAL_PAIR_COPY_CTOR=0 for __APPLE__, no longer needed.
llvm-svn: 195796
2013-11-27 00:53:02 +00:00
Marshall Clow e34f6f6a12 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.
llvm-svn: 195785
2013-11-26 20:58:02 +00:00
Joerg Sonnenberger c55d97b1f9 Don't use T as template argument, it is part of the application
namespace.

llvm-svn: 195693
2013-11-25 22:44:20 +00:00
Yaron Keren e050d66e12 Compiling libcxx with gcc 4.6.4 (MingW) produces these errors:
type_traits:3280:31: error: expected primary-expression before 'decltype'
 type_traits:3280:29: error: expected ';' at end of member declaration

 memory:2415:49: error: function 'std::__1::default_delete<_Tp>::default_delete()'
 defaulted on its first declaration must not have an exception-specification

 memory:2435:49: error: function 'std::__1::default_delete<_Tp []>::default_delete()'
 defaulted on its first declaration must not have an exception-specification

The attached patch defines _LIBCPP_HAS_NO_ADVANCED_SFINAE and 
_LIBCPP_HAS_NO_DEFAULTED_FUNCTIONS for gcc version < 4.7, making
the library compile with gcc 4.6.4.

llvm-svn: 195431
2013-11-22 09:22:12 +00:00
Marshall Clow 028875aa7c Patch by Xing Xue to improve libc++ support for AIX
llvm-svn: 195144
2013-11-19 19:16:03 +00:00
Marshall Clow eed0bdee59 Fix a test that I broke over the weekend
llvm-svn: 195143
2013-11-19 19:14:27 +00:00
Marshall Clow 7e1ea8d288 Patch by Bruce Mitchener. Change all references to EMSCRIPTEN to __EMSCRIPTEN__. If you're not using the PP symbol EMSCRIPTEN, then you should see no functionality change.
llvm-svn: 195136
2013-11-19 18:05:03 +00:00
Yaron Keren f16f037060 G M suggestion: conditionally include files on _WIN32.
llvm-svn: 195045
2013-11-18 21:30:19 +00:00
Yaron Keren fbeb63c0d1 This patch implements snprintf_l function in a way similar to the other
functions in src/support/win32/locale_win32.cpp and locale_win32.h, 
calling upon vsnprintf for which there is a MingW correct alternative.

Note! __USE_MINGW_ANSI_STDIO is not modified in this patch. In order to 
use the __mingw version it must be defined before including the MingW 
headers.

llvm-svn: 195044
2013-11-18 21:12:14 +00:00
Bill Wendling 39d0c93b70 Set the permissions for 'experimental' and its context to the correct values.
llvm-svn: 194993
2013-11-18 07:01:16 +00:00