Version 2 of Higher order TIP discuss

Updated 2010-04-15 20:14:11 by escargo

Discussion page for [L1 ], a proposal for Higher Order Functions in Tcl that is intended to result in a TIP.


escargo 15 Apr 2010 - There appears to be some damage to the page in the reference link. One heading is tr;dr. Headings for "Introduction, Motivation and Goals," "A review of FP and higher order functions in Tcl," and "The design of this proposal" appear to be missing.

One feature of the design of the proposal is described like this:

filter predicate list is a filter over a list, and predicate is a cmdprefix that must return a boolean.

This is somewhat imprecise in that Tcl does not have a boolean data type. More firmly specified would be to say that cmdprefix must return 0 or 1.

The discussion about optional arguments would clarified if the distinction between formal arguments and actual arguments were more clearly drawn.

While proponents of functional programming might know about left fold and right fold an explanatory reference for the rest of us would be welcome.