Robert Fisher

Just thinking out loud

Kinds of procedures

If you register and log in you can add comments to my pages. If viewing the main blog page, click the # underneath an entry to comment on it.

  • Nested: A procedure declared/defined within the scope of another procedure.
  • Open/closed: A closure is a type of procedure that captures its environment. EcmaScript & Scheme have closures. The distinction only makes sense if you have nested procedures?
  • First-class: If a procedure can be assigned to a variable, passed as an argument, returned, & applied indirectly; it is a first-class procedure. C, EcmaScript, & Scheme have first-class procedures.
  • Anonymous: A first-class procedure that doesn't need to be given a name. EcmaScript & Scheme have anonymous procedures.
  • Higher-order: Procedures that take other procedures as arguments or return procedures.

Downward funargs is being able to pass a procedure as a parameter? Upwards funargs is being able to return a procedure?