Marshall Clow
cf355fc373
Implement P0972R0: <chrono> zero(), min(), and max() should be noexcept. Reviewed as https://reviews.llvm.org/D53828
...
llvm-svn: 346766
2018-11-13 17:22:41 +00:00
Marshall Clow
5b08c1742a
Recommit <chrono> changes with a couple xtra tests marked to fail on apple's clang. Reviewed as D51762
...
llvm-svn: 344627
2018-10-16 17:27:54 +00:00
Artem Dergachev
a9bc0face5
Revert r344529 "Implement the first part of the calendar support for C++20"
...
Revert r344535 "Wrap up the new chrono literals in an #ifdef..."
Revert r344546 "Mark a couple of test cases as 'C++17-only'..."
Some of the buildbot failures were masked by another error,
and this one was probably missed.
llvm-svn: 344580
2018-10-16 02:40:42 +00:00
Marshall Clow
323e01d46f
Wrap up the new chrono literals in an #ifdef so that old versions of clang don't complain. I'm looking at you, clang 5.0.1
...
llvm-svn: 344535
2018-10-15 17:33:20 +00:00
Marshall Clow
06ba9f5246
Implement the first part of the calendar support for C++20. This is still incomplete; there will be more patches coming. Reviewed as D51762
...
llvm-svn: 344529
2018-10-15 16:06:37 +00:00
Marshall Clow
f56972e224
Implement the infrastructure for feature-test macros. Very few actual feature test macros, though. Reviewed as: https://reviews.llvm.org/D51955
...
llvm-svn: 342073
2018-09-12 19:41:40 +00:00
Marshall Clow
d0ab67f7d0
Last week, someone noted that a couple of the time_point member functions were not constexpr. I looked, and they were right. They were made constexpr in p0505, so I looked at all the other bits in that paper to make sure that I didn't miss anything else. There were a couple methods in the synopsis that should have been marked constexpr, but the code was correct.
...
llvm-svn: 340992
2018-08-29 23:02:15 +00:00
Louis Dionne
7c3492b00d
[NFC][libc++] Consistently use spaces to indent
...
rdar://problem/19988944
llvm-svn: 338933
2018-08-03 22:36:53 +00:00
Marshall Clow
da77fe4a77
Update the synopsis for <chrono> for C++20. No functional change.
...
llvm-svn: 337406
2018-07-18 17:37:51 +00:00
Marshall Clow
40a01d5314
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).
...
llvm-svn: 321658
2018-01-02 17:17:01 +00:00
Marshall Clow
162484f7da
Change the way the literal operators are defined - now w/o a seperating space. This should be a NFC, but it will change how the compiler parses it.
...
llvm-svn: 310487
2017-08-09 15:42:50 +00:00
Eric Fiselier
a016efb1dc
[Libc++] Use #pragma push_macro/pop_macro to better handle min/max on Windows
...
Summary:
This patch improves how libc++ handles min/max macros within the headers. Previously libc++ would undef them and emit a warning.
This patch changes libc++ to use `#pragma push_macro` to save the macro before undefining it, and `#pragma pop_macro` to restore the macros and the end of the header.
Reviewers: mclow.lists, bcraig, compnerd, EricWF
Reviewed By: EricWF
Subscribers: cfe-commits, krytarowski
Differential Revision: https://reviews.llvm.org/D33080
llvm-svn: 304357
2017-05-31 22:07:49 +00:00
Marshall Clow
9bd9ed4d23
Implement P0548: 'common_type and duration' This involves a subtle change in the return type of the unary +/- operators for std::chrono::duration, though I expect that no one will notice.
...
llvm-svn: 298416
2017-03-21 18:38:57 +00:00
Eric Fiselier
e2f2d1edef
[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.
llvm-svn: 291035
2017-01-04 23:56:00 +00:00
Marshall Clow
dbf7ca9ce6
Implement P0505: 'Wording for GB 50'
...
llvm-svn: 291028
2017-01-04 23:03:24 +00:00
Eric Fiselier
f9980200aa
Remove _LIBCPP_HAS_NO_DEFAULTED_FUNCTIONS
...
libc++ no longer supports C++11 compilers that don't implement `= default`.
This patch removes all instances of the feature test macro
_LIBCPP_HAS_NO_DEFAULTED_FUNCTIONS as well as the potentially dead code it hides.
llvm-svn: 287321
2016-11-18 06:42:17 +00:00
Marshall Clow
1c7fe126ee
Fixes for LWG 2598, 2686, 2739, 2742, 2747, and 2759, which were adopted last week in Issaquah
...
llvm-svn: 286858
2016-11-14 18:22:19 +00:00
Marshall Clow
b8427293df
Last bit of P0006; mark it as complete
...
llvm-svn: 254290
2015-11-30 05:39:30 +00:00
Marshall Clow
2cd0d6d625
Implement P0092R1 for C++1z
...
llvm-svn: 252195
2015-11-05 19:33:59 +00:00
Jonathan Roelofs
c59e585126
Partially address a FIXME in steady_clock::now()
...
http://reviews.llvm.org/D4045
llvm-svn: 216949
2014-09-02 21:14:38 +00:00
Marshall Clow
3ceafc7f01
Mark namespaces for user defined literals as 'inline'
...
llvm-svn: 192047
2013-10-05 21:18:32 +00:00
Howard Hinnant
69bc206547
SFINAE out duration converting constructor if the constructor would otherwise cause a ratio compile-time overflow. This fixes LWG 2094.
...
llvm-svn: 189722
2013-08-31 16:51:56 +00:00
Howard Hinnant
f0544c2086
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 >.
...
llvm-svn: 188192
2013-08-12 18:38:34 +00:00
Howard Hinnant
d098713aaf
War on tabs
...
llvm-svn: 187906
2013-08-07 19:39:48 +00:00
Marshall Clow
df67172d59
Backwards!
...
llvm-svn: 187518
2013-07-31 19:39:37 +00:00
Marshall Clow
a1d0d376c8
Implement n3469 - constexpr for chrono
...
llvm-svn: 187517
2013-07-31 19:32:19 +00:00
Marshall Clow
7aa54577d1
literal suffixes for std::chrono
...
llvm-svn: 187078
2013-07-24 21:18:14 +00:00
Howard Hinnant
e0fe3d2e96
War on tabs.
...
llvm-svn: 185865
2013-07-08 21:06:38 +00:00
Howard Hinnant
afe8b967cc
Dimitry Andric: Add const to constexpr member functions in order to cope with new C++1y language rules. This silences -Wconstexpr-not-const warnings.
...
llvm-svn: 185181
2013-06-28 18:09:35 +00:00
Howard Hinnant
6e41256f68
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.
...
llvm-svn: 176593
2013-03-06 23:30:19 +00:00
Argyrios Kyrtzidis
88db3171dd
Don't neglect to "return *this".
...
llvm-svn: 165860
2012-10-13 02:03:45 +00:00
Howard Hinnant
c033115394
Applied constexpr to <chrono>.
...
llvm-svn: 160184
2012-07-13 19:17:27 +00:00
Howard Hinnant
ab4f438239
Add protection from min/max macros
...
llvm-svn: 145407
2011-11-29 16:45:27 +00:00
Howard Hinnant
073458b1ab
Windows support by Ruben Van Boxem.
...
llvm-svn: 142235
2011-10-17 20:05:10 +00:00
Howard Hinnant
ce48a1137d
_STD -> _VSTD to avoid macro clash on windows
...
llvm-svn: 134190
2011-06-30 21:18:19 +00:00
Howard Hinnant
d53d81522d
noexcept for <chrono>.
...
llvm-svn: 132265
2011-05-28 18:34:36 +00:00
Howard Hinnant
3dc6455ff0
N3191: C++ Timeout Specification
...
llvm-svn: 119909
2010-11-20 19:16:30 +00:00
Howard Hinnant
412dbebe1b
license change
...
llvm-svn: 119395
2010-11-16 22:09:02 +00:00
Howard Hinnant
fb100021b7
visibility-decoration.
...
llvm-svn: 114486
2010-09-21 21:28:23 +00:00
Howard Hinnant
e31e36f910
[rand.dist.norm.f]
...
llvm-svn: 104035
2010-05-18 17:32:30 +00:00
Howard Hinnant
5b08a8a432
Wiped out some non-ascii characters that snuck into the copyright.
...
llvm-svn: 103516
2010-05-11 21:36:01 +00:00
Howard Hinnant
3e519524c1
libcxx initial import
...
llvm-svn: 103490
2010-05-11 19:42:16 +00:00