MCPcopy Create free account
hub / github.com/astral-sh/ruff / with_capacity

Method with_capacity

crates/ruff_python_parser/src/parser/scratch_buffer.rs:17–21  ·  view source on GitHub ↗
(capacity: usize)

Source from the content-addressed store, hash-verified

15 }
16
17 pub(super) fn with_capacity(capacity: usize) -> Self {
18 Self {
19 buffer: Vec::with_capacity(capacity),
20 }
21 }
22
23 #[inline]
24 pub(super) fn push(&mut self, value: T) {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected