pub fn strategy(
        target_features: impl Strategy<Value = TargetFeatures>,
    ) -> impl Strategy<Value = Platform> {
        let flags = btree_set(flag_strategy(), 0..3);
        (0..ALL_BUILTINS.len(), target_features, flags).prop_map(|(idx, target_features, flags)| {
            let mut platform = Platform::new(
                ALL_BUILTINS[idx].triple.as_str().to_owned(),
                target_features,
            )
            .expect("known triple");
            platform.add_flags(flags);
            platform
        })
    }
Given a way to generate `TargetFeatures` instances, this returns a `Strategy` that generates
a platform at random.

Requires the `proptest1` feature to be enabled.

## Examples

```
use proptest::prelude::*;
use target_spec::{Platform, TargetFeatures};

// target_features is a strategy that always produces TargetFeatures::Unknown.
let target_features = Just(TargetFeatures::Unknown);
let strategy = Platform::strategy(target_features);
```
target-spec/src/proptest_helpers.rs