Version française
Home     About     Download     Resources     Contact us    

This site is updated infrequently. For up-to-date information, please visit the new OCaml website at

Browse thread
[Caml-list] Evaluation Order
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2001-06-10 (02:22)
From: David McClain <dmcclain1@m...>
Subject: Re: [Caml-list] Evaluation Order
> The idea is to annotate the type of any functional result with the
> fact that it has escaping side-effects.  Then to not let any
> so-annotated value be used directly in an expression.  Let's look at
> David's problem:

I had just thought of a similar solution myself, but I wouldn't be so strict
as to disallow any use in an expression. Rather, as long as only one such
function call exists in any one expression it would be okay. That would
allow things like

let ans = prev_ans + process_tail() in ....

It does sound like an easy solution, so knowing myself as I do, I am
wondering what I don't understand about the details... If it were so easy,
then why hasn't it been done yet?

- DM

Bug reports:  FAQ:
To unsubscribe, mail  Archives: