// `array.set` out of range stops the actor, on both backends; the native // runtime releases the array and the value it was given. import std/array import std/io pub fn main :: -> () / { let a = array.from_list ["x", "y", "z"] io.println (show (array.set a 2 "w")) let b = array.set a 3 "never stored" io.println ("never printed " <> show b) } //> [x, y, w] //! panic: array.set: index 3 out of range for length 3