Decimal as quasi-parser (Was: [Caja] Fwd: ES3.1 Draft: 07 Nov 2008 "Kona" version available)
On Thu, Nov 6, 2008 at 2:33 PM, Mark S. Miller <erights at google.com>
wrote:
The EcmaScript 3.1 draft standard is rapidly congealing towards an
official
standard. The Kona version at <
es3.1:es3.1_proposal_working_draft>
is the important one -- details aside, the only remaining significant unsettled controversy is whether Decimal remains or is pulled from
ES3.1.
This was settled in Redmond: if Sam Ruby could do the necessary work in time for Kona (and, yes, details/bugs are almost always present and fixable) decimal support is in 3.1.
Sam has done that work, so there is no controversy at this point. ECMAScript 3.1 is looking good, and looks as though it will have industry-wide support.
Mike
Unless stated otherwise above: IBM United Kingdom Limited - Registered in England and Wales with number 741598. Registered office: PO Box 41, North Harbour, Portsmouth, Hampshire PO6 3AU
Mike Cowlishaw wrote:
On Thu, Nov 6, 2008 at 2:33 PM, Mark S. Miller <erights at google.com> wrote:
The EcmaScript 3.1 draft standard is rapidly congealing towards an official standard. The Kona version at es3.1:es3.1_proposal_working_draft
is the important one -- details aside, the only remaining significant unsettled controversy is whether Decimal remains or is pulled from ES3.1.
This was settled in Redmond: if Sam Ruby could do the necessary work in time for Kona (and, yes, details/bugs are almost always present and fixable) decimal support is in 3.1.
Sam has done that work, so there is no controversy at this point. ECMAScript 3.1 is looking good, and looks as though it will have industry-wide support.
The number of Decimal-related bugs in the Kona draft is alarmingly high. I suspect that it will scrape in, but I definitely wouldn't say it was uncontroversial.
On Thu, Nov 6, 2008 at 2:33 PM, Mark S. Miller <erights at google.com> wrote:
It seems the desire to add Decimal to Javascript is a special case of the generic desire to have custom syntax inline in a Javascript program. In this case, the desire is to manipulate Decimal objects using math operators. Is there any chance this issue could be side-stepped by adding support for quasi-parsers, like in the E language? So instead of:
0.1m + 0.1m
you'd have:
m
0.1 + 0.1
The variable m would be initialized to some implementation in Javascript. VMs that recognize this implementation code could then substitute their own more efficient native implementation. Other VMs just execute the provided implementation as normal Javascript code.