tcl::mathop::lt
tcl::mathop::lt ?arg ...?
The string order operators of Tcl 9.1: lt, gt, le, and ge. In expr they compare two values as strings, with the precedence of <. As a command, each one gives 1 when each pair of neighbor arguments is in the order.
This page also has tcl::mathop::gt, tcl::mathop::le, tcl::mathop::ge.
Examples
expr {"10" lt "9"}gives1expr {"b" ge "a"}gives1tcl::mathop::lt a b cgives1
Facts
- Capability: none.
- Compute cost: one compute unit for the call, and more for the commands that it runs.
- Release: Tcl 9.1 only. A script has the command when ztcl follows Tcl 9.1, with
--tcl 9.1. See Tcl 9.1.