17 #ifndef _SCC_SC_ATTRIBUTE_RANDOMIZED_H_
18 #define _SCC_SC_ATTRIBUTE_RANDOMIZED_H_
20 #include "mt19937_rng.h"
21 #include <sysc/kernel/sc_attribute.h>
22 #include <type_traits>
33 : sc_core::sc_attribute<T>(name_) {}
36 : sc_core::sc_attribute<T>(name_) {}
39 : sc_core::sc_attribute<T>(a.name()) {}
45 template <
bool cond,
typename U>
using resolvedType =
typename std::enable_if<cond, U>::type;
47 template <
typename U = T> resolvedType<std::is_signed<T>::value, U> get_value() {
54 template <
typename U = T> resolvedType<std::is_unsigned<T>::value, U> get_value() {
return this->value; }
static uint64_t uniform()