[Haskell-cafe] Unsafe IO and Wash
Simon Marlow
simonmar at microsoft.com
Wed Feb 16 10:01:28 EST 2005
On 16 February 2005 14:28, John Goerzen wrote:
> On Wed, Feb 16, 2005 at 07:16:50AM +0100, Tomasz Zielonka wrote:
>> On Wed, Feb 16, 2005 at 04:33:29AM +0000, John Goerzen wrote:
>>> On a related note, Wash seems to be preserving all sorts of
>>> unnecessary "state" from previous screens a user visited.
>>
>> You do know that the current version of WASH rebuilds the
>> continuation by repeating all the previous steps, don't you? Until
>> WASH can keep the
>
> Yes. What I don't understand is why. If I have a submit button, and
> it is passing one value to the next function, and that value is from
> an
> entry form on the screen, why would I care about all the previous
> state? That's my confusion. It seems unnecessary.
WASH would have to store the value of the next function in the log, as a
continuation. If that is a top-level function then it's easy, but WASH
lets you use an arbitrary expression as the continuation, which might
include an arbitrary amount of data captured in the free variables.
Storing this continuation directly in the web page would require
low-level trawling of the Haskell heap. WASH's Haskell-only solution is
so neat because it doesn't need to do this: it just recreates the
continuation by recording how it was created.
Cheers,
Simon
More information about the Haskell-Cafe
mailing list