Well if you consult the bible Structure and Interpretation of Computer Programs 
by Abelson, Sussman, and Sussman, the term function is strictly reserved for 
mathematical objects, and procedure is uniformly used for what people loosely 
call functions.

As to the discussion about the distinction between procedure and function in 
other languages, from a pure functional programming viewpoint a procedure in 
Pascal and so on is called purely for its side effects, on global variables 
(horror!) for example,  which is why it does not return a value, and this is a 
complete abomination. Of course Scheme is a functional language but not pure 
like Haskell, so this is academic in the context of lilypond. Still preferable 
to avoid procedures that are invoked purely for side effects whether your 
language is pure or impure.

So the guile manual is correct to uniformly use the term procedure. But if you 
look at the Racket manual they consistently use the term Functions (Procedures) 
in headings, so they are somewhat looser.

In short, procedure and function are most certainly not synonyms in Scheme 
terminology.

Andrew

_______________________________________________
lilypond-user mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/lilypond-user

Reply via email to