MCPcopy Index your code
hub / github.com/RustPython/RustPython / insert

Method insert

crates/common/src/boxvec.rs:103–105  ·  view source on GitHub ↗
(&mut self, index: usize, element: T)

Source from the content-addressed store, hash-verified

101 }
102
103 pub fn insert(&mut self, index: usize, element: T) {
104 self.try_insert(index, element).unwrap()
105 }
106
107 pub fn try_insert(&mut self, index: usize, element: T) -> Result<(), CapacityError<T>> {
108 if index > self.len() {

Callers 15

insert_separatorMethod · 0.45
inline_comprehensionFunction · 0.45
analyze_symbol_tableMethod · 0.45
found_in_outer_scopeMethod · 0.45
add_classdict_freevarMethod · 0.45
scan_type_paramsMethod · 0.45
register_nameMethod · 0.45
enter_scopeMethod · 0.45

Calls 2

try_insertMethod · 0.80
unwrapMethod · 0.45

Tested by

no test coverage detected