pub fn filtered_strategy(
        triple_filter: impl Fn(&'static str) -> bool,
        target_features: impl Strategy<Value = TargetFeatures>,
    ) -> impl Strategy<Value = Platform> {
        let filtered: Vec<_> = ALL_BUILTINS
            .iter()
            .filter(|target_info| triple_filter(target_info.triple.as_str()))
            .collect();
        let flags = btree_set(flag_strategy(), 0..3);
        (0..filtered.len(), target_features, flags).prop_map(
            move |(idx, target_features, flags)| {
                let mut platform = Platform::new(filtered[idx].triple.as_str(), target_features)
                    .expect("known triple");
                platform.add_flags(flags);
                platform
            },
        )
    }
A version of `strategy` that allows target triples to be filtered.

Requires the `proptest1` feature to be enabled.
target-spec/src/proptest_helpers.rs