diff options
| author | Marshall Clow <mclow.lists@gmail.com> | 2018-01-02 17:17:01 +0000 |
|---|---|---|
| committer | Marshall Clow <mclow.lists@gmail.com> | 2018-01-02 17:17:01 +0000 |
| commit | 40a01d5314ffc3c5f4c379cd69015f962dde5f72 (patch) | |
| tree | 33725944bdc9f3baa95beb2ee8612d1a6c1dbaf5 /libcxx/include/chrono | |
| parent | 2640a0a5e576ed0474cebc6efd89fe65e1ebbd38 (diff) | |
| download | bcm5719-llvm-40a01d5314ffc3c5f4c379cd69015f962dde5f72.tar.gz bcm5719-llvm-40a01d5314ffc3c5f4c379cd69015f962dde5f72.zip | |
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
Diffstat (limited to 'libcxx/include/chrono')
| -rw-r--r-- | libcxx/include/chrono | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/libcxx/include/chrono b/libcxx/include/chrono index c69e88ae4de..809f773b6c6 100644 --- a/libcxx/include/chrono +++ b/libcxx/include/chrono @@ -26,7 +26,7 @@ duration_cast(const duration<Rep, Period>& fd); template <class Rep> struct treat_as_floating_point : is_floating_point<Rep> {}; -template <class Rep> constexpr bool treat_as_floating_point_v +template <class Rep> inline constexpr bool treat_as_floating_point_v = treat_as_floating_point<Rep>::value; // C++17 template <class Rep> @@ -419,7 +419,8 @@ template <class _Rep> struct _LIBCPP_TEMPLATE_VIS treat_as_floating_point : is_floating_point<_Rep> {}; #if _LIBCPP_STD_VER > 14 && !defined(_LIBCPP_HAS_NO_VARIABLE_TEMPLATES) -template <class _Rep> _LIBCPP_CONSTEXPR bool treat_as_floating_point_v +template <class _Rep> +_LIBCPP_INLINE_VAR _LIBCPP_CONSTEXPR bool treat_as_floating_point_v = treat_as_floating_point<_Rep>::value; #endif |

