Code
Hub
Workspaces
Following
Digest
Agents
Trending
Connect
MCP
copy
Index your code
hub
/
github.com/RustPython/RustPython
/ borrow_bytes
Method
borrow_bytes
crates/vm/src/function/buffer.rs:157–162 ·
view source on GitHub ↗
(&self)
Source
from the content-addressed store, hash-verified
155
156
impl ArgStrOrBytesLike {
157
pub fn borrow_bytes(&self) -> BorrowedValue<'_, [u8]> {
158
match self {
159
Self::Buf(b) => b.borrow_buf(),
160
Self::Str(s) => s.as_bytes().into(),
161
}
162
}
163
}
164
165
#[derive(Debug)]
Callers
6
rand_add
Function · 0.80
extract_address
Method · 0.80
fcntl
Function · 0.80
ioctl
Function · 0.80
compile
Function · 0.80
eval
Function · 0.80
Calls
2
borrow_buf
Method · 0.45
as_bytes
Method · 0.45
Tested by
no test coverage detected