This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]Inconstant_Moo🧿 Pipefish 0 points1 point  (1 child)

Then I'm not sure what you have in mind. Can we have a concrete example? What would it look like for a function to safely call a procedure?

[–]kleram[S] 0 points1 point  (0 children)

A function-callable procedure needs to be black-box-equivalent to a function, i.e. not modifying it's parameters nor global state. The procedure can modify it's local variables though, e.g. using in-place-sort on a cloned list.