world as value

Adrian Hey ahey@iee.org
Mon, 19 Jul 1999 00:23:45 +0100 (BST)


On Thu 15 Jul, P.R. Serrarens wrote:
> Exactly.

Or maybe not.. Although a general compiler solution to this problem
is not possible, I think it would be possible to have a system which
allowed artificial dependency to control the order in which things happened
if it was important. In fact that's all world as value really is, in
my humble opinion. Unfortunately, it seems an especially constraining
form of artificial dependency because it requires all actions to be chained
together in a linear sequence.

Suppose instead, we had something like a 'non-deterministic do' which
was basically a collection of actions (_not_ functions) which could be
performed in any order we (the scheduler) like or concurrently, subject to
satisfying dependency constraints (real or artificial). Of course this
collection of actions would not be a proper value, and the
'non-deterministic do' would not be a function, so any language which
contained such a construct would not be purely functional. Also, since such
a scheme would never explicitly reference the environment being manipulated,
it also need not be a proper value. It could simply be 'the world', and
so may contain all sorts of nasties like mutable non-unique values and
'self changing' values (like time perhaps).
  
This is the kind of thing I'm thinking about. Obviously there's a lot more
than could be said about the pros and cons of such a scheme, but that's all
I'll say for now.

Regards
-- 
Adrian Hey