English version
Accueil     À propos     Téléchargement     Ressources     Contactez-nous    

Ce site est rarement mis à jour. Pour les informations les plus récentes, rendez-vous sur le nouveau site OCaml à l'adresse ocaml.org.

Browse thread
[Caml-list] generic programming
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2002-07-05 (23:02)
From: Dave Berry <daveb@t...>
Subject: Re: [Caml-list] Re: generic programming
At 10:33 05/07/2002, Francois Pottier wrote:
>My memories of STL are vague, but if an iterator is what I think it
>is, then implementing one in O'Caml is pretty straightforward. An
>iterator is a function that returns a function which maintains a
>piece of internal state. 

But can you compile it down to a single increment instruction on a pointer
(for an iterator over an array)?

Also, can you compare two iterators for equality?

To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr
Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/
Beginner's list: http://groups.yahoo.com/group/ocaml_beginners