Function patch_seq_roll
Source #[unsafe(no_mangle)]
pub unsafe extern "C" fn patch_seq_roll(stack: Stack) -> Stack
Expand description
Roll: Rotate n+1 items, bringing the item at depth n to the top
( x_n x_(n-1) … x_1 x_0 n – x_(n-1) … x_1 x_0 x_n )
§Safety
Stack must have at least n+1 values (plus the index value).
§Panics
- If the top value is not an Int
- If n is negative
- If n exceeds the current stack depth