pub(crate) enum ArrView {
Live(ObjRef, usize),
Owned(Vec<Value>),
}Expand description
反復する配列の見え方。本物の配列は写さず、長さだけ最初に決めて要素は訪れたときに読む(仕様どおり。
途中で縮んで無くなった要素は飛ばす)。それ以外(array-like・型付き配列)は従来どおり写す。
【2026-11-04】forEach/map/filter が呼ぶたびに配列全体を写しており、確保と memcpy の呼び出し元の上位だった。
Variants§
Implementations§
Auto Trait Implementations§
impl !RefUnwindSafe for ArrView
impl !Send for ArrView
impl !Sync for ArrView
impl !UnwindSafe for ArrView
impl Freeze for ArrView
impl Unpin for ArrView
impl UnsafeUnpin for ArrView
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more