Debian Codegraph @

src/impls/alloc/btreeset.rs

raw symbols SCIP
1 use craterust-analyzer cargo cc-traits 2.0.0 crate/::{
2 Clearrust-analyzer cargo cc-traits 2.0.0 Clear#, Collectionrust-analyzer cargo cc-traits 2.0.0 Collection#, CollectionMutrust-analyzer cargo cc-traits 2.0.0 CollectionMut#, CollectionRefrust-analyzer cargo cc-traits 2.0.0 CollectionRef#, Getrust-analyzer cargo cc-traits 2.0.0 Get#, Insertrust-analyzer cargo cc-traits 2.0.0 Insert#, Iterrust-analyzer cargo cc-traits 2.0.0 Iter#, Lenrust-analyzer cargo cc-traits 2.0.0 Len#, Removerust-analyzer cargo cc-traits 2.0.0 Remove#,
3 SimpleCollectionMutrust-analyzer cargo cc-traits 2.0.0 SimpleCollectionMut#, SimpleCollectionRefrust-analyzer cargo cc-traits 2.0.0 SimpleCollectionRef#,
4 };
5 use allocrust-analyzer cargo alloc https://github.com/rust-lang/rust/library/alloc crate/::collectionsrust-analyzer cargo alloc https://github.com/rust-lang/rust/library/alloc collections/::BTreeSetrust-analyzer cargo alloc https://github.com/rust-lang/rust/library/alloc collections/btree/set/BTreeSet#;
6 use corerust-analyzer cargo core https://github.com/rust-lang/rust/library/core crate/::borrowrust-analyzer cargo core https://github.com/rust-lang/rust/library/core borrow/::Borrowrust-analyzer cargo core https://github.com/rust-lang/rust/library/core borrow/Borrow#;
7
8 impl<T> Collectionrust-analyzer cargo cc-traits 2.0.0 Collection# for BTreeSetrust-analyzer cargo alloc https://github.com/rust-lang/rust/library/alloc collections/btree/set/BTreeSet#<T> {
9 type Itemrust-analyzer cargo cc-traits 2.0.0 impls/alloc/btreeset/impl#[`BTreeSet<T>`][Collection]Item# = T;
10 }
11
12 impl<T> CollectionRefrust-analyzer cargo cc-traits 2.0.0 CollectionRef# for BTreeSetrust-analyzer cargo alloc https://github.com/rust-lang/rust/library/alloc collections/btree/set/BTreeSet#<T> {
13 type ItemRefrust-analyzer cargo cc-traits 2.0.0 impls/alloc/btreeset/impl#[`BTreeSet<T>`][CollectionRef]ItemRef#<'a> = &'a T where Selfrust-analyzer cargo cc-traits 2.0.0 impls/alloc/btreeset/impl#[`BTreeSet<T>`][CollectionRef]: 'a;
14
15 craterust-analyzer cargo cc-traits 2.0.0 crate/::covariant_item_refrust-analyzer cargo cc-traits 2.0.0 macros/covariant_item_ref!!();
16 }
17
18 impl<T> CollectionMutrust-analyzer cargo cc-traits 2.0.0 CollectionMut# for BTreeSetrust-analyzer cargo alloc https://github.com/rust-lang/rust/library/alloc collections/btree/set/BTreeSet#<T> {
19 type ItemMutrust-analyzer cargo cc-traits 2.0.0 impls/alloc/btreeset/impl#[`BTreeSet<T>`][CollectionMut]ItemMut#<'a> = &'a mut T where Selfrust-analyzer cargo cc-traits 2.0.0 impls/alloc/btreeset/impl#[`BTreeSet<T>`][CollectionMut]: 'a;
20
21 craterust-analyzer cargo cc-traits 2.0.0 crate/::covariant_item_mutrust-analyzer cargo cc-traits 2.0.0 macros/covariant_item_mut!!();
22 }
23
24 impl<T> SimpleCollectionRefrust-analyzer cargo cc-traits 2.0.0 SimpleCollectionRef# for BTreeSetrust-analyzer cargo alloc https://github.com/rust-lang/rust/library/alloc collections/btree/set/BTreeSet#<T> {
25 craterust-analyzer cargo cc-traits 2.0.0 crate/::simple_collection_refrust-analyzer cargo cc-traits 2.0.0 macros/simple_collection_ref!!();
26 }
27
28 impl<T> SimpleCollectionMutrust-analyzer cargo cc-traits 2.0.0 SimpleCollectionMut# for BTreeSetrust-analyzer cargo alloc https://github.com/rust-lang/rust/library/alloc collections/btree/set/BTreeSet#<T> {
29 craterust-analyzer cargo cc-traits 2.0.0 crate/::simple_collection_mutrust-analyzer cargo cc-traits 2.0.0 macros/simple_collection_mut!!();
30 }
31
32 impl<T> Lenrust-analyzer cargo cc-traits 2.0.0 Len# for BTreeSetrust-analyzer cargo alloc https://github.com/rust-lang/rust/library/alloc collections/btree/set/BTreeSet#<T> {
33 #[inline(always)]
34 fn lenrust-analyzer cargo cc-traits 2.0.0 impls/alloc/btreeset/impl#[`BTreeSet<T>`][Len]len().(&self) -> usize {
35 self.lenrust-analyzer cargo alloc https://github.com/rust-lang/rust/library/alloc collections/btree/set/impl#[`BTreeSet<T, A>`]len().()
36 }
37
38 #[inline(always)]
39 fn is_emptyrust-analyzer cargo cc-traits 2.0.0 impls/alloc/btreeset/impl#[`BTreeSet<T>`][Len]is_empty().(&self) -> bool {
40 self.is_emptyrust-analyzer cargo alloc https://github.com/rust-lang/rust/library/alloc collections/btree/set/impl#[`BTreeSet<T, A>`]is_empty().()
41 }
42 }
43
44 impl<'a, Q, T: Ordrust-analyzer cargo core https://github.com/rust-lang/rust/library/core cmp/Ord#> Getrust-analyzer cargo cc-traits 2.0.0 Get#<&'a Q> for BTreeSetrust-analyzer cargo alloc https://github.com/rust-lang/rust/library/alloc collections/btree/set/BTreeSet#<T>
45 where
46 T: Borrowrust-analyzer cargo core https://github.com/rust-lang/rust/library/core borrow/Borrow#<Q>,
47 Q: Ordrust-analyzer cargo core https://github.com/rust-lang/rust/library/core cmp/Ord# + ?Sizedrust-analyzer cargo core https://github.com/rust-lang/rust/library/core marker/Sized#,
48 {
49 #[inline(always)]
50 fn getrust-analyzer cargo cc-traits 2.0.0 impls/alloc/btreeset/impl#[`BTreeSet<T>`][`Get<&'a Q>`]get().(&self, t: &'a Q) -> Optionrust-analyzer cargo core https://github.com/rust-lang/rust/library/core option/Option#<&T> {
51 self.getrust-analyzer cargo alloc https://github.com/rust-lang/rust/library/alloc collections/btree/set/impl#[`BTreeSet<T, A>`]get().(t)
52 }
53 }
54
55 impl<T: Ordrust-analyzer cargo core https://github.com/rust-lang/rust/library/core cmp/Ord#> Insertrust-analyzer cargo cc-traits 2.0.0 Insert# for BTreeSetrust-analyzer cargo alloc https://github.com/rust-lang/rust/library/alloc collections/btree/set/BTreeSet#<T> {
56 type Outputrust-analyzer cargo cc-traits 2.0.0 impls/alloc/btreeset/impl#[`BTreeSet<T>`][Insert]Output# = bool;
57
58 #[inline(always)]
59 fn insertrust-analyzer cargo cc-traits 2.0.0 impls/alloc/btreeset/impl#[`BTreeSet<T>`][Insert]insert().(&mut self, t: T) -> bool {
60 self.insertrust-analyzer cargo alloc https://github.com/rust-lang/rust/library/alloc collections/btree/set/impl#[`BTreeSet<T, A>`]insert().(t)
61 }
62 }
63
64 impl<'a, Q, T: Ordrust-analyzer cargo core https://github.com/rust-lang/rust/library/core cmp/Ord#> Removerust-analyzer cargo cc-traits 2.0.0 Remove#<&'a Q> for BTreeSetrust-analyzer cargo alloc https://github.com/rust-lang/rust/library/alloc collections/btree/set/BTreeSet#<T>
65 where
66 T: Borrowrust-analyzer cargo core https://github.com/rust-lang/rust/library/core borrow/Borrow#<Q>,
67 Q: Ordrust-analyzer cargo core https://github.com/rust-lang/rust/library/core cmp/Ord# + ?Sizedrust-analyzer cargo core https://github.com/rust-lang/rust/library/core marker/Sized#,
68 {
69 #[inline(always)]
70 fn removerust-analyzer cargo cc-traits 2.0.0 impls/alloc/btreeset/impl#[`BTreeSet<T>`][`Remove<&'a Q>`]remove().(&mut self, t: &'a Q) -> Optionrust-analyzer cargo core https://github.com/rust-lang/rust/library/core option/Option#<T> {
71 self.takerust-analyzer cargo alloc https://github.com/rust-lang/rust/library/alloc collections/btree/set/impl#[`BTreeSet<T, A>`]take().(t)
72 }
73 }
74
75 impl<T: Ordrust-analyzer cargo core https://github.com/rust-lang/rust/library/core cmp/Ord#> Clearrust-analyzer cargo cc-traits 2.0.0 Clear# for BTreeSetrust-analyzer cargo alloc https://github.com/rust-lang/rust/library/alloc collections/btree/set/BTreeSet#<T> {
76 #[inline(always)]
77 fn clearrust-analyzer cargo cc-traits 2.0.0 impls/alloc/btreeset/impl#[`BTreeSet<T>`][Clear]clear().(&mut self) {
78 self.clearrust-analyzer cargo alloc https://github.com/rust-lang/rust/library/alloc collections/btree/set/impl#[`BTreeSet<T, A>`]clear().()
79 }
80 }
81
82 impl<T> Iterrust-analyzer cargo cc-traits 2.0.0 Iter# for BTreeSetrust-analyzer cargo alloc https://github.com/rust-lang/rust/library/alloc collections/btree/set/BTreeSet#<T> {
83 type Iterrust-analyzer cargo cc-traits 2.0.0 impls/alloc/btreeset/impl#[`BTreeSet<T>`][Iter]Iter#<'a> = allocrust-analyzer cargo alloc https://github.com/rust-lang/rust/library/alloc crate/::collectionsrust-analyzer cargo alloc https://github.com/rust-lang/rust/library/alloc collections/::btree_setrust-analyzer cargo alloc https://github.com/rust-lang/rust/library/alloc collections/btree_set/::Iterrust-analyzer cargo alloc https://github.com/rust-lang/rust/library/alloc collections/btree/set/Iter#<'a, T> where Selfrust-analyzer cargo cc-traits 2.0.0 impls/alloc/btreeset/impl#[`BTreeSet<T>`][Iter]: 'a;
84
85 #[inline(always)]
86 fn iterrust-analyzer cargo cc-traits 2.0.0 impls/alloc/btreeset/impl#[`BTreeSet<T>`][Iter]iter().(&self) -> Selfrust-analyzer cargo cc-traits 2.0.0 impls/alloc/btreeset/impl#[`BTreeSet<T>`][Iter]::Iterrust-analyzer cargo cc-traits 2.0.0 Iter#Iter#<'_> {
87 self.iterrust-analyzer cargo alloc https://github.com/rust-lang/rust/library/alloc collections/btree/set/impl#[`BTreeSet<T, A>`]iter().()
88 }
89 }