Version 8 of until

Updated 2014-01-25 15:56:47 by dkf

The procedure until is not in the core, but you can define it yourself as follows:

proc until {cond code} {
    uplevel 1 [list while !$cond $code]
}

See also control::do (in tcllib).

This doesn't implement the usual meaning of until, which executes the code and then tests cond after.

DKF: The usual definition is typically expressed as a do-while loop, which is a form that puts the test last. When expressed condition-first, it is natural to expect the condition to be checked first...