Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 2 additions & 8 deletions libcxx/include/__random/discard_block_engine.h
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,8 @@ class _LIBCPP_TEMPLATE_VIS discard_block_engine {
typedef typename _Engine::result_type result_type;

// engine characteristics
static _LIBCPP_CONSTEXPR const size_t block_size = __p;
static _LIBCPP_CONSTEXPR const size_t used_block = __r;
static inline _LIBCPP_CONSTEXPR const size_t block_size = __p;
static inline _LIBCPP_CONSTEXPR const size_t used_block = __r;

#ifdef _LIBCPP_CXX03_LANG
static const result_type _Min = _Engine::_Min;
Expand Down Expand Up @@ -110,12 +110,6 @@ class _LIBCPP_TEMPLATE_VIS discard_block_engine {
operator>>(basic_istream<_CharT, _Traits>& __is, discard_block_engine<_Eng, _Pp, _Rp>& __x);
};

template <class _Engine, size_t __p, size_t __r>
_LIBCPP_CONSTEXPR const size_t discard_block_engine<_Engine, __p, __r>::block_size;

template <class _Engine, size_t __p, size_t __r>
_LIBCPP_CONSTEXPR const size_t discard_block_engine<_Engine, __p, __r>::used_block;

template <class _Engine, size_t __p, size_t __r>
typename discard_block_engine<_Engine, __p, __r>::result_type discard_block_engine<_Engine, __p, __r>::operator()() {
if (__n_ >= static_cast<int>(__r)) {
Expand Down
24 changes: 4 additions & 20 deletions libcxx/include/__random/linear_congruential_engine.h
Original file line number Diff line number Diff line change
Expand Up @@ -251,12 +251,12 @@ class _LIBCPP_TEMPLATE_VIS linear_congruential_engine {
static_assert(_Min < _Max, "linear_congruential_engine invalid parameters");

// engine characteristics
static _LIBCPP_CONSTEXPR const result_type multiplier = __a;
static _LIBCPP_CONSTEXPR const result_type increment = __c;
static _LIBCPP_CONSTEXPR const result_type modulus = __m;
static inline _LIBCPP_CONSTEXPR const result_type multiplier = __a;
static inline _LIBCPP_CONSTEXPR const result_type increment = __c;
static inline _LIBCPP_CONSTEXPR const result_type modulus = __m;
_LIBCPP_HIDE_FROM_ABI static _LIBCPP_CONSTEXPR result_type min() { return _Min; }
_LIBCPP_HIDE_FROM_ABI static _LIBCPP_CONSTEXPR result_type max() { return _Max; }
static _LIBCPP_CONSTEXPR const result_type default_seed = 1u;
static inline _LIBCPP_CONSTEXPR const result_type default_seed = 1u;

// constructors and seeding functions
#ifndef _LIBCPP_CXX03_LANG
Expand Down Expand Up @@ -318,22 +318,6 @@ class _LIBCPP_TEMPLATE_VIS linear_congruential_engine {
operator>>(basic_istream<_CharT, _Traits>& __is, linear_congruential_engine<_Up, _Ap, _Cp, _Np>& __x);
};

template <class _UIntType, _UIntType __a, _UIntType __c, _UIntType __m>
_LIBCPP_CONSTEXPR const typename linear_congruential_engine<_UIntType, __a, __c, __m>::result_type
linear_congruential_engine<_UIntType, __a, __c, __m>::multiplier;

template <class _UIntType, _UIntType __a, _UIntType __c, _UIntType __m>
_LIBCPP_CONSTEXPR const typename linear_congruential_engine<_UIntType, __a, __c, __m>::result_type
linear_congruential_engine<_UIntType, __a, __c, __m>::increment;

template <class _UIntType, _UIntType __a, _UIntType __c, _UIntType __m>
_LIBCPP_CONSTEXPR const typename linear_congruential_engine<_UIntType, __a, __c, __m>::result_type
linear_congruential_engine<_UIntType, __a, __c, __m>::modulus;

template <class _UIntType, _UIntType __a, _UIntType __c, _UIntType __m>
_LIBCPP_CONSTEXPR const typename linear_congruential_engine<_UIntType, __a, __c, __m>::result_type
linear_congruential_engine<_UIntType, __a, __c, __m>::default_seed;

template <class _UIntType, _UIntType __a, _UIntType __c, _UIntType __m>
template <class _Sseq>
void linear_congruential_engine<_UIntType, __a, __c, __m>::__seed(_Sseq& __q, integral_constant<unsigned, 1>) {
Expand Down
Loading
Loading