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
This commit is contained in:
@@ -292,7 +292,7 @@ _LIBCPP_BEGIN_NAMESPACE_STD
|
||||
namespace chrono
|
||||
{
|
||||
|
||||
template <class _Rep, class _Period = ratio<1> > class _LIBCPP_TYPE_VIS duration;
|
||||
template <class _Rep, class _Period = ratio<1> > class _LIBCPP_TYPE_VIS_ONLY duration;
|
||||
|
||||
template <class _Tp>
|
||||
struct __is_duration : false_type {};
|
||||
@@ -312,8 +312,8 @@ struct __is_duration<const volatile duration<_Rep, _Period> > : true_type {};
|
||||
} // chrono
|
||||
|
||||
template <class _Rep1, class _Period1, class _Rep2, class _Period2>
|
||||
struct _LIBCPP_TYPE_VIS common_type<chrono::duration<_Rep1, _Period1>,
|
||||
chrono::duration<_Rep2, _Period2> >
|
||||
struct _LIBCPP_TYPE_VIS_ONLY common_type<chrono::duration<_Rep1, _Period1>,
|
||||
chrono::duration<_Rep2, _Period2> >
|
||||
{
|
||||
typedef chrono::duration<typename common_type<_Rep1, _Rep2>::type,
|
||||
typename __ratio_gcd<_Period1, _Period2>::type> type;
|
||||
@@ -390,10 +390,10 @@ duration_cast(const duration<_Rep, _Period>& __fd)
|
||||
}
|
||||
|
||||
template <class _Rep>
|
||||
struct _LIBCPP_TYPE_VIS treat_as_floating_point : is_floating_point<_Rep> {};
|
||||
struct _LIBCPP_TYPE_VIS_ONLY treat_as_floating_point : is_floating_point<_Rep> {};
|
||||
|
||||
template <class _Rep>
|
||||
struct _LIBCPP_TYPE_VIS duration_values
|
||||
struct _LIBCPP_TYPE_VIS_ONLY duration_values
|
||||
{
|
||||
public:
|
||||
_LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR _Rep zero() {return _Rep(0);}
|
||||
@@ -404,7 +404,7 @@ public:
|
||||
// duration
|
||||
|
||||
template <class _Rep, class _Period>
|
||||
class _LIBCPP_TYPE_VIS duration
|
||||
class _LIBCPP_TYPE_VIS_ONLY duration
|
||||
{
|
||||
static_assert(!__is_duration<_Rep>::value, "A duration representation can not be a duration");
|
||||
static_assert(__is_ratio<_Period>::value, "Second template parameter of duration must be a std::ratio");
|
||||
@@ -715,7 +715,7 @@ operator%(const duration<_Rep1, _Period1>& __lhs, const duration<_Rep2, _Period2
|
||||
//////////////////////////////////////////////////////////
|
||||
|
||||
template <class _Clock, class _Duration = typename _Clock::duration>
|
||||
class _LIBCPP_TYPE_VIS time_point
|
||||
class _LIBCPP_TYPE_VIS_ONLY time_point
|
||||
{
|
||||
static_assert(__is_duration<_Duration>::value,
|
||||
"Second template parameter of time_point must be a std::chrono::duration");
|
||||
@@ -759,8 +759,8 @@ public:
|
||||
} // chrono
|
||||
|
||||
template <class _Clock, class _Duration1, class _Duration2>
|
||||
struct _LIBCPP_TYPE_VIS common_type<chrono::time_point<_Clock, _Duration1>,
|
||||
chrono::time_point<_Clock, _Duration2> >
|
||||
struct _LIBCPP_TYPE_VIS_ONLY common_type<chrono::time_point<_Clock, _Duration1>,
|
||||
chrono::time_point<_Clock, _Duration2> >
|
||||
{
|
||||
typedef chrono::time_point<_Clock, typename common_type<_Duration1, _Duration2>::type> type;
|
||||
};
|
||||
|
Reference in New Issue
Block a user