Performs a linear scan of buf from [0 .. buf.length$(RP), replacing elements where pred returns true with val.
The array to scan.
The value to substitute.
The evaluation predicate, which should return true if the element is a valid match and false if not. This predicate may be any callable type.
The number of elements replaced.
See Implementation
Performs a linear scan of buf from [0 .. buf.length$(RP), replacing elements where pred returns true with val.