Suppose I have the following struct:
struct Data {
float zs[50];
};
I'm trying to create a rapidcheck generator similarly to the ones defined here such as:
// NOTE: Must be in rc namespace!
namespace rc {
template<>
struct Arbitrary<Person> {
static Gen<Person> arbitrary() {
return gen::build<Person>(
gen::set(&Person::firstName),
gen::set(&Person::lastName),
gen::set(&Person::age, gen::inRange(0, 100)));
}
};
} // namespace rc
Is this possible?