Re: Syntax, expressiveness and the beauty of Tcl
- From: Kevin Kenny <kennykb@xxxxxxx>
- Date: Mon, 30 Oct 2006 18:54:18 -0500
Eckhard Lehmann wrote:
That all looks very weird and complex. What about a simple and strict
polish notation, like in LISP:
proc + {a b} {expr {$a + $b}}
proc - {a b} {expr {$a - $b}}
proc * {a b} {expr {$a * $b}}
proc / {a b} {expr {$a / $b}}
set res [+ [* 7 8] [- 8 9]]
55
Every operator is a command as well and it is compatible with the rest
of Tcl (although it will be even less familiar to the majority of
programmers)
TIP #174 (http://tip.tcl.tk/174) is being voted on this week.
It provides exactly the Cambridge Polish (not RPN, the "reverse"
in RPN indicates that the operator comes *last*) notation that
you request.
--
73 de ke9tv/2, Kevin
forth love if honk else forth learn then
.
- Follow-Ups:
- References:
- Syntax, expressiveness and the beauty of Tcl
- From: Stephan Kuhagen
- Re: Syntax, expressiveness and the beauty of Tcl
- From: Christian Gollwitzer
- Re: Syntax, expressiveness and the beauty of Tcl
- From: Eckhard Lehmann
- Syntax, expressiveness and the beauty of Tcl
- Prev by Date: Re: XOTcl + Actiweb
- Next by Date: Re: Syntax, expressiveness and the beauty of Tcl
- Previous by thread: Re: Syntax, expressiveness and the beauty of Tcl
- Next by thread: Re: Syntax, expressiveness and the beauty of Tcl
- Index(es):
Relevant Pages
|
|