pub fn insert(&mut self, element: A::Item) -> bool {
        match self.find(&element) {
            Ok(_) => false,
            Err(idx) => {
                self.vec.insert(idx, element);
                true
            }
        }
    }
/// Adds an element to the set.
///
/// If the set did not have this element present, `true` is returned.
///
/// If the set did have this element present, `false` is returned, and the
/// entry is not updated.
///
/// # Examples
///
/// ```
/// use small_ord_set::SmallOrdSet;
///
/// let mut set = SmallOrdSet::<[u32; 4]>::new();
///
/// assert_eq!(set.insert(2), true);
/// assert_eq!(set.insert(2), false);
/// assert_eq!(set.len(), 1);
/// ```
Adds an element to the set.
If the set did not have this element present, `true` is returned.

If the set did have this element present, `false` is returned, and the
entry is not updated.
Adds an element to the set . If the set did not have this element present ` true ` is returned . If the set did have this element present ` false ` is returned and the entry is not updated .
pub fn insert(&mut self, element: A::Item) -> bool {
        match self.find(&element) {
            Ok(_) => false,
            Err(idx) => {
                self.vec.insert(idx, element);
                true
            }
        }
    }
pub fn insert ( & mut self , element : A :: Item ) -> bool { match self . find ( & element ) { Ok ( _ ) => false , Err ( idx ) => { self . vec . insert ( idx , element ) ; true } } }
Adds an element to the set.
Adds an element to the set .
&mut self
element
A::Item
&mut self
element
A::Item
examples
```
use small_ord_set::SmallOrdSet.




` ` ` use small_ord_set :: SmallOrdSet .