#![allow(unused_variables)] #![feature(btree_set_entry)] fn main() { use std::collections::btree_set::{Entry, BTreeSet}; let mut set = BTreeSet::new(); match set.entry("poneyland") { Entry::Occupied(_) => panic!(), Entry::Vacant(v) => assert_eq!(v.into_value(), "poneyland"), } }