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] Function forward declaration?
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2004-04-07 (14:15)
From: Richard Jones <rich@a...>
Subject: Re: [Caml-list] Function forward declaration?
On Wed, Apr 07, 2004 at 11:52:17PM +1000, skaller wrote:
> IMHO it isn't forward calling that is broken, 
> but global variables.

A somewhat controversial viewpoint ...  While minimising the use of
global variables might be a theoretical desirable goal, they are very
useful when you're actually writing real programs under the schedule
pressure for real users..

> > and this can be checked by the compiler.
> How? *** 
> What do you suggest if the compiler
> is not sure if a variable is initialised or not?
> Java bans, Felix allows, Ocaml forces the programmer
> to hack.

The trouble seems to be that I have a perfectly practical and
reasonable desire to see prototypes added to the language, because,
believe it or now, it helps to solve some problems in the Real World.
Now if there's some deep reason why it's actually impossible I would
understand, but plenty of other languages (eg. C) seem to have
prototypes and they get along just fine.

(Same, by the way, goes for a 'return' statement which OCaml is crying
out for).


Richard Jones.
Merjis Ltd. - improving website return on investment - CRM improvement consultancy

To unsubscribe, mail Archives:
Bug reports: FAQ:
Beginner's list: