[clean-list] Clean's answer to the Functional Achilles-heel

Mark Phillips mark@austrics.com.au
Thu, 27 Dec 2001 15:55:20 +1030


Hi All,

The last year or so I have been trying to teach myself a little
about about various different programming paradigms.  I am hoping
to form a "big picture" perspective of the advantages and 
disadvantages of different forms of programming.  Hopefully this
will enable me to make informed judgements about which languages
to invest my time with.  I have a question which I hope people
on this list will be able to answer.

The Achilles-heel of functional programming seems to be interaction
with the outside world.  The Functional/Logic approach, as I understand
it, is to model the relationships between different entities.  The F/L
approach works best when one wishes only to observe, without disturbing,
this world of relationships unfold its implications before you.  You
are to look but not touch.  Sure you can manipulate the rules and
relationships within this world, but the world, as an entity, is not
well equipped to interact with the outside.  Put in other terms: the F/L paradigm does not sit well with I/O (nor does it model interaction of
objects with time-dependent states that well).  Perhaps I am wrong, but
that is the impression I have gained.

I realize that the various schools of Functional/Logic thought have
implemented mechanisms attempting to overcome these difficulties, but
if I understand correctly, none of the current solutions is entirely
statisfactory.  Each proposed solution has its drawbacks.  No approach
has emerged to be _the_ answer.  Am I wrong?  Am I exaggerating the 
extent of the difficulties?

So now to my main question:

    In simple terms, what is Clean's approach to overcomming these
    difficulties?  What are the advantages and disadvantages?  How
    does it compare with the approaches of other Functional/Logic
    languages?

Thanks,

Mark.