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

Function cross_chunk_push_pop

crates/vm/src/datastack.rs:234–245  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

232
233 #[test]
234 fn cross_chunk_push_pop() {
235 let mut ds = DataStack::new();
236 // Push enough to force a new chunk
237 let mut ptrs = Vec::new();
238 for _ in 0..100 {
239 ptrs.push(ds.push(1024));
240 }
241 // Pop all in reverse
242 for p in ptrs.into_iter().rev() {
243 unsafe { ds.pop(p) };
244 }
245 }
246
247 #[test]
248 fn alignment() {

Callers

nothing calls this directly

Calls 5

newFunction · 0.85
pushMethod · 0.45
revMethod · 0.45
into_iterMethod · 0.45
popMethod · 0.45

Tested by

no test coverage detected