Commit Graph

37 Commits

Author SHA1 Message Date
Thomas A
a574ade231 Downgrading libcxx to llvmorg-13.0.1
It turns out that llvmorg-14.0.6 might be too new for dyld (the vector base class no longer exist in that release).
2022-06-26 13:05:32 -07:00
Thomas A
e3bbeb7fdc Update libcxx source to llvmorg-14.0.6 2022-06-26 09:13:52 -07:00
Chandler Carruth
7c3769df62 Update more file headers across all of the LLVM projects in the monorepo
to reflect the new license. These used slightly different spellings that
defeated my regular expressions.

We understand that people may be surprised that we're moving the header
entirely to discuss the new license. We checked this carefully with the
Foundation's lawyer and we believe this is the correct approach.

Essentially, all code in the project is now made available by the LLVM
project under our new license, so you will see that the license headers
include that license only. Some of our contributors have contributed
code under our old license, and accordingly, we have retained a copy of
our old license notice in the top-level files in each project and
repository.

git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@351648 91177308-0d34-0410-b5e6-96231b3b80d8
2019-01-19 10:56:40 +00:00
Louis Dionne
6952d1478d [libc++] Remove _LIBCPP_BUILDING_XXX macros, which are redundant since _LIBCPP_BUILDING_LIBRARY
Summary: As suggested by Marshall in https://reviews.llvm.org/D49914

Reviewers: mclow.lists, EricWF

Subscribers: christof, dexonsmith, cfe-commits

Differential Revision: https://reviews.llvm.org/D50008

git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@338475 91177308-0d34-0410-b5e6-96231b3b80d8
2018-08-01 02:08:59 +00:00
Louis Dionne
54238057d6 [libc++] Take 2: Replace uses of _LIBCPP_ALWAYS_INLINE by _LIBCPP_INLINE_VISIBILITY
Summary:
We never actually mean to always inline a function -- all the uses of
the macro I could find are actually attempts to control the visibility
of symbols. This is better described by _LIBCPP_INLINE_VISIBILITY, which
is actually always defined the same.

This change is orthogonal to the decision of what we're actually going
to do with _LIBCPP_INLINE_VISIBILITY -- it just simplifies things by
having one canonical way of doing things.

Note that this commit had originally been applied in r336369 and then
reverted in r336382 because of unforeseen problems. Both of these problems
have now been fixed.

Reviewers: EricWF, mclow.lists

Subscribers: christof, dexonsmith, erikvanderpoel

Differential Revision: https://reviews.llvm.org/D48892

git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@336866 91177308-0d34-0410-b5e6-96231b3b80d8
2018-07-11 23:14:33 +00:00
Louis Dionne
4e7ffcaae6 Revert "[libc++] Replace uses of _LIBCPP_ALWAYS_INLINE by _LIBCPP_INLINE_VISIBILITY"
This reverts commit r336369. The commit had two problems:
1. __pbump was marked as _LIBCPP_EXTERN_TEMPLATE_INLINE_VISIBILITY instead of
   _LIBCPP_INLINE_VISIBILITY, which lead to two symbols being added in the
   dylib and the check-cxx-abilist failing.

2. The LLDB tests started failing because they undefine
   `_LIBCPP_INLINE_VISIBILITY`. I need to figure out why they do that and
   fix the tests before we can go forward with this change.

git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@336382 91177308-0d34-0410-b5e6-96231b3b80d8
2018-07-05 18:41:50 +00:00
Louis Dionne
79aa4f32d0 [libc++] Replace uses of _LIBCPP_ALWAYS_INLINE by _LIBCPP_INLINE_VISIBILITY
Summary:
We never actually mean to always inline a function -- all the uses of
the macro I could find are actually attempts to control the visibility
of symbols. This is better described by _LIBCPP_INLINE_VISIBILITY, which
is actually always defined the same.

This change is orthogonal to the decision of what we're actually going
to do with _LIBCPP_INLINE_VISIBILITY -- it just simplifies things by
having one canonical way of doing things.

Reviewers: EricWF

Subscribers: christof, llvm-commits, dexonsmith, erikvanderpoel, mclow.lists

Differential Revision: https://reviews.llvm.org/D48892

git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@336369 91177308-0d34-0410-b5e6-96231b3b80d8
2018-07-05 16:49:38 +00:00
Zhihao Yuan
8deb2dd30a [libc++] Lift std::errc into a separated header
Summary: This is needed to implement `<charconv>`, otherwise `<charconv>` would need to include `<system_error>`, which pulls in `<string>` -- a header which the `<charconv>` proposal intends to keep away from.

Reviewers: mclow.lists, EricWF

Reviewed By: mclow.lists

Subscribers: christof, cfe-commits

Differential Revision: https://reviews.llvm.org/D41347

git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@336164 91177308-0d34-0410-b5e6-96231b3b80d8
2018-07-03 03:25:10 +00:00
Marshall Clow
c58e4723e7 Implement most of P0607: Inline Variables for the Standard Library. This involved marking a lot of variables as inline (but only for C++17 and later).
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@321658 91177308-0d34-0410-b5e6-96231b3b80d8
2018-01-02 17:17:01 +00:00
Marshall Clow
ff400da261 Add include of <string> to <system_error>, since things in there return strings. Fixes PR#34529.
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@312923 91177308-0d34-0410-b5e6-96231b3b80d8
2017-09-11 16:05:42 +00:00
Eric Fiselier
a7ae303de3 Add ABI option to remove recently inlined __shared_count functions from the library.
In order to allow inlining of previously out-of-line functions without an ABI break
libc++ provides legacy definitions in the dylib that old programs can
continue to use. Unfortunatly Windows link.exe detects this hack and diagnoses the duplicate
definitions.

This patch disable the duplicate definitions on Windows by adding an ABI option
which disables all "legacy out-of-line symbols"

git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@292190 91177308-0d34-0410-b5e6-96231b3b80d8
2017-01-17 03:16:26 +00:00
Eric Fiselier
c3589a8305 [NFC] Rename _LIBCPP_TYPE_VIS_ONLY to _LIBCPP_TEMPLATE_VIS
The name _LIBCPP_TYPE_VIS_ONLY is no longer accurate because both
_LIBCPP_TYPE_VIS and _LIBCPP_TYPE_VIS_ONLY expand to
__attribute__((__type_visibility__)) with Clang. The only remaining difference
is that _LIBCPP_TYPE_VIS_ONLY can be applied to templates whereas
_LIBCPP_TYPE_VIS cannot (due to dllimport/dllexport not being allowed on
templates).

This patch renames _LIBCPP_TYPE_VIS_ONLY to _LIBCPP_TEMPLATE_VIS.

git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@291035 91177308-0d34-0410-b5e6-96231b3b80d8
2017-01-04 23:56:00 +00:00
Eric Fiselier
4b07f98816 Introduce _LIBCPP_DEPRECATED_ABI_EXTERNAL_ERROR_CATEGORY_CONSTRUCTOR ABI option.
Currently libc++ compiles a special version of error_category()
into the dylib. This definition is no longer needed, and doesn't
work on Windows due to dllimport/dllexport semantics.

For those reasons this patch introduces an option to
disable/enable this definition. By default the definition
is provided in ABI v1 except on windows. This patch
also addresses D28210.

git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@290840 91177308-0d34-0410-b5e6-96231b3b80d8
2017-01-02 22:17:51 +00:00
Marshall Clow
db7fa111ab Fixes for LWG 2598, 2686, 2739, 2742, 2747, and 2759, which were adopted last week in Issaquah
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@286858 91177308-0d34-0410-b5e6-96231b3b80d8
2016-11-14 18:22:19 +00:00
Marshall Clow
db86684746 Implement is_error_code_v and is_error_condition_v for c++17. Rework the tests for is_error_code and is_error_condition, since they were really lacking. Thanks to Alisdair for the heads-up that we were missing these.
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@282331 91177308-0d34-0410-b5e6-96231b3b80d8
2016-09-24 17:36:14 +00:00
Aditya Kumar
5db6737a36 Add attribute noreturn to functions that throw
Reviewers: mclow.lists, EricWF, howard.hinnant, sebpop
Subscribers: cfe-commits

Differential Revision: https://reviews.llvm.org/D21232

git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@279903 91177308-0d34-0410-b5e6-96231b3b80d8
2016-08-27 02:26:42 +00:00
Eric Fiselier
e2d4892682 Fix most GCC warnings during build. Only -Wattribute left.
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@246280 91177308-0d34-0410-b5e6-96231b3b80d8
2015-08-28 07:02:42 +00:00
Howard Hinnant
fc3f80badf G M: Improve support for compilers not supporting defaulted functions.
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@189184 91177308-0d34-0410-b5e6-96231b3b80d8
2013-08-24 21:31:37 +00:00
Howard Hinnant
8a1df3ca0c David Blaikie suggested this test for detecting constexpr on the error_category default constructor. Additionally I decided to make this constructor trivial as well, as I could not come up with a rationale for not doing so. Fully tested with both current Apple clang and tip-of-trunk clang.
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@189034 91177308-0d34-0410-b5e6-96231b3b80d8
2013-08-22 17:41:48 +00:00
Marshall Clow
5c316a6d04 LWG 2145 - mark constructor for std::error_category as inline and constexpr. Leave the (existing, out-of-line, non-constexpr) in the dylib for compatibility with existing programs)
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@188858 91177308-0d34-0410-b5e6-96231b3b80d8
2013-08-21 02:57:19 +00:00
Howard Hinnant
0f678bd69e Nico Rieck: this patch series fixes visibility issues on Windows as explained in <http://lists.cs.uiuc.edu/pipermail/cfe-dev/2013-August/031214.html>.
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@188192 91177308-0d34-0410-b5e6-96231b3b80d8
2013-08-12 18:38:34 +00:00
Howard Hinnant
83eade6abb No functionality change at this time. I've split _LIBCPP_VISIBLE up into two flags: _LIBCPP_TYPE_VIS and _LIBCPP_FUNC_VIS. This is in preparation for taking advantage of clang's new __type_visibility__ attribute.
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@176593 91177308-0d34-0410-b5e6-96231b3b80d8
2013-03-06 23:30:19 +00:00
Howard Hinnant
9c0df1416f Rename uses of _ and __ because these are getting stepped on by macros from other system code.
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@167038 91177308-0d34-0410-b5e6-96231b3b80d8
2012-10-30 19:06:59 +00:00
Howard Hinnant
33be35effe Dimitry Andric: many visibility fixes. Howard: Much appreciated. Can you send me a patch to CREDITS.TXT?
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@163862 91177308-0d34-0410-b5e6-96231b3b80d8
2012-09-14 00:39:16 +00:00
Howard Hinnant
9aa4e11451 It appears that the standard accidentally removed the default constructor for error_category. I'm putting it back in. This fixes http://llvm.org/bugs/show_bug.cgi?id=12321.
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@153194 91177308-0d34-0410-b5e6-96231b3b80d8
2012-03-21 16:18:57 +00:00
Howard Hinnant
7786188d15 Modernize conversion to bool to the explicit bool conversion operator (library wide). This fixes http://llvm.org/bugs/show_bug.cgi?id=12058.
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@151088 91177308-0d34-0410-b5e6-96231b3b80d8
2012-02-21 21:46:43 +00:00
Howard Hinnant
f6d875f7f5 Fix http://llvm.org/bugs/show_bug.cgi?id=11428. Fix provided by Alberto Ganesh Barbati
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@145698 91177308-0d34-0410-b5e6-96231b3b80d8
2011-12-02 19:36:40 +00:00
Howard Hinnant
ec3773c2da Quash a whole bunch of warnings
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@145624 91177308-0d34-0410-b5e6-96231b3b80d8
2011-12-01 20:21:04 +00:00
Howard Hinnant
9996844df0 Further macro protection by replacing _[A-Z] with _[A-Z]p
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@145410 91177308-0d34-0410-b5e6-96231b3b80d8
2011-11-29 18:15:50 +00:00
Howard Hinnant
08e17472e4 Windows support by Ruben Van Boxem.
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@142235 91177308-0d34-0410-b5e6-96231b3b80d8
2011-10-17 20:05:10 +00:00
Howard Hinnant
1e15fd1856 Applied noexcept to everything in [diagnostics] (Chapter 19)
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@132137 91177308-0d34-0410-b5e6-96231b3b80d8
2011-05-26 19:48:01 +00:00
Howard Hinnant
b64f8b07c1 license change
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@119395 91177308-0d34-0410-b5e6-96231b3b80d8
2010-11-16 22:09:02 +00:00
Howard Hinnant
8d7a9557b7 visibility-decoration.
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@114671 91177308-0d34-0410-b5e6-96231b3b80d8
2010-09-23 17:31:07 +00:00
Howard Hinnant
324bb03bb9 Fixing whitespace problems
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@111750 91177308-0d34-0410-b5e6-96231b3b80d8
2010-08-22 00:02:43 +00:00
David Chisnall
81e68580b2 #ifdef around Solaris/Linux/Darwin-specific error codes and replace them with their BSD equivalents if they are not available.
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@110827 91177308-0d34-0410-b5e6-96231b3b80d8
2010-08-11 16:52:41 +00:00
Howard Hinnant
f5256e16df Wiped out some non-ascii characters that snuck into the copyright.
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@103516 91177308-0d34-0410-b5e6-96231b3b80d8
2010-05-11 21:36:01 +00:00
Howard Hinnant
bc8d3f97eb libcxx initial import
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@103490 91177308-0d34-0410-b5e6-96231b3b80d8
2010-05-11 19:42:16 +00:00