C. Scott Ananian
ecmascript at cscott.net
Mon Jun 30 10:09:36 PDT 2014
On Mon, Jun 30, 2014 at 1:01 PM, Rick Waldron <waldron.rick at gmail.com>
> Just because other languages don't include a TAU constant doesn't mean
> ECMAScript cannot.
> Just because "serious mathematicians" think this is "crackpot territory",
> doesn't mean it's not useful (the condescension of that claim certainly
As I mentioned, although I am a pi-ist, I think Math.TAU is harmless. But
I will qualify the "not useful" part -- there is no numerical accuracy
benefit to using Math.TAU (only the floating point exponent changes), nor
is there likely to be any emitted-code improvement (constant propagation
being a standard part of any reasonable runtime). So the benefit is solely
the single character minimized code size improvement from '2*Math.PI' to
'Math.TAU' (if this were significant wouldn't the minimizers be assigning
this to a single-character variable already?), and the the code readability
improvement of using Math.TAU (assuming the readers of your code are also
So I would be highly skeptical of any claim to "utility". I am, however,
sympathetic to the idea that many users will feel TAU to be "fun" -- which
does have its (limited) place in language design.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the es-discuss