Skip to content

Commit

Permalink
Make BTreeSet::new_in const
Browse files Browse the repository at this point in the history
  • Loading branch information
Kritzefitz committed Oct 9, 2023
1 parent bbc2304 commit d60b43c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion library/alloc/src/collections/btree/set.rs
Original file line number Diff line number Diff line change
Expand Up @@ -358,7 +358,7 @@ impl<T, A: Allocator + Clone> BTreeSet<T, A> {
/// let mut set: BTreeSet<i32> = BTreeSet::new_in(Global);
/// ```
#[unstable(feature = "btreemap_alloc", issue = "32838")]
pub fn new_in(alloc: A) -> BTreeSet<T, A> {
pub const fn new_in(alloc: A) -> BTreeSet<T, A> {
BTreeSet { map: BTreeMap::new_in(alloc) }
}

Expand Down

0 comments on commit d60b43c

Please sign in to comment.