Re: [TCLCORE] TIP #266: Numbers are Commands
by Arjen Markus other posts by this author
Apr 13 2006 12:00AM messages near this date
[TCLCORE] TIP #266: Numbers are Commands
|
Re: [TCLCORE] TIP #266: Numbers are Commands
Hello Kristoffer,
> There is an existing proposal for making operands into commands. That
> proposal is still a valid one, but the description in this TIP leads to
> syntax which will be more familiar to most programmers. It does not
> have operator precedence, which is a difference from normal
> mathematics, but one that should be easier to grasp than the reversed
> notation that operator commands offer. In fact, there are many claims
> which state operator precedence is a mistake anyway.
>
There is also TIP 232 which proposes to make [expr] functions available as
ordinary Tcl commands and which makes it possible to make ordinary Tcl
commands (and procs) available as [expr] functions.
My position in this discussion is somewhat opposite to yours, though:
- The [expr] command with its mathematically inspired infix notation
is a much better fit for anyone doing more complicated computations than
[incr], in my biased(*) opinion (* biased as I have a
physical-mathematical
background with a preference for numerical applications ...).
- I would love to see the [expr]-syntax become available for complex
numbers,
vectors and so on - much as I do with <http://wiki.tcl.tk/15703>
- I am not alone in this: one common criticism of Tcl is that you can
not have
ordinary assignment statement like f = a + b ...
Probably there are simply two schools of thought to be distinguished and
each
will defend its position with ferver!
Regards,
Arjen
>
>
-------------------------------------------------------
This SF.Net email is sponsored by xPML, a groundbreaking scripting language
that extends applications into web and mobile media. Attend the live webcast
and join the prime developer group breaking into this new coding territory!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642
_______________________________________________
Tcl-Core mailing list
Tcl-Core@[...].net
https://lists.sourceforge.net/lists/listinfo/tcl-core
Thread:
Kristoffer Lawson
Arjen Markus
Peter MacDonald
Kristoffer Lawson
Peter MacDonald
Kristoffer Lawson
Peter MacDonald
Kristoffer Lawson
Arjen Markus
dgp
Arjen Markus
Brian Griffin
Peter MacDonald
Kristoffer Lawson
Gustaf Neumann
Donal K. Fellows
Donald G Porter
Neil Madden
David N. Welton
Arjen Markus
Kristoffer Lawson
Neil Madden
Kristoffer Lawson
Lars Hellström
Neil Madden
Kristoffer Lawson
|