interface Iterable f where
iterate : f a -> (a -> () with e) -> () with IterEff f | e
PréludeChargé par défaut — aucun
import nécessaire.Iterable — one interface for everything for x in <c> can walk
Synopsis
iterateArrFrom : Array a -> Int -> Int -> (a -> () with e) -> () with Mut | e
A LIVE array: each element read is getArr (a Mut operation), so the instance declares effect IterEff = Mut — iterating an Array carries with Mut in its effect row, visibly. (The instance lives here with its interface; the Array operations themselves stay with the Mut effect.) The instance's counted walk, as DIRECT tail recursion — deliberately no internal var/while: their desugared local runMut region, once the method is INLINED under a caller's runMut, hits the C backend's nested- runMut miscompile (pre-existing; repro + fixture routed to the backend chantier). Same constant-stack regime as whileLoop.