W3C home > Mailing lists > Public > whatwg@whatwg.org > May 2006

[whatwg] Side effects free scripts

From: Alexey Feldgendler <alexey@feldgendler.ru>
Date: Thu, 01 Jun 2006 13:05:43 +0700
Message-ID: <op.tagdvti31h6og4@localhost>
On Thu, 01 Jun 2006 11:21:02 +0700, liorean <liorean at gmail.com> wrote:

> The problem is that verifying whether function may result in side
> effects is a pain that must be delayed until runtime. You cannot know
> that methods, functions or constructors are side effect free unless
> they are host objects and readonly. You can't even assume that
>     hello+' world';
> is side effect free since the hello variable might contain an object
> with a toString method that has side effects.
>
> So, determining if a function is side effect free needs to be done
> while that function is run.

It's not a problem. There's no need to verify that the function is side effects free until runtime.


-- 
Alexey Feldgendler <alexey at feldgendler.ru>
[ICQ: 115226275] http://feldgendler.livejournal.com
Received on Wednesday, 31 May 2006 23:05:43 UTC

This archive was generated by hypermail 2.3.1 : Monday, 13 April 2015 23:08:27 UTC