Version française
Home     About     Download     Resources     Contact us    
Browse thread
speed versus C
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Michel Quercia <quercia@c...>
Subject: Re: speed versus C
William Chesters :
:   Incidentally, implementing a Vector in ocaml is slightly fiddly,
: because you have to keep valid pointers of the right type in even the
: unused part all the time.  This means o.a. delaying the creation of
: the underlying array until you have at least one element to put in it.

I disagree, better fill-in the vector with dummy values on creation (fe.
Val_unit), otherwise you may keep pointers to data that can not be reclaimed,
though semantically unreachable.

Gerd.Stolpmann :
: Caml is simply not good at arrays. I think it is not a good idea to adopt too
: much imperative style.

Please, let the user decide by himself if he wants to write imperative or
functionnal code. Depending on the particular problem he his solving, his own
preferences and sometimes also the weather of the day, he may choose one or the
other style or even mix both. Why not ?

--
Michel Quercia
9/11 rue du grand rabbin Haguenauer, 54000 Nancy
http://pauillac.inria.fr/~quercia
mailto:quercia@cal.enst.fr