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] Some more code written by a newbie to be reviewed by *real* O'Caml coders :)
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2001-07-02 (06:52)
From: Jeremy Fincher <tweedgeezer@h...>
Subject: [Caml-list] Some more code written by a newbie to be reviewed by *real* O'Caml coders :)
I'm fairly new to O'Caml, and I hope that a few more experienced O'Caml 
programmers can review some of the code I've written to show me how things 
can be done better, what parts I've done that stray from O'Caml idiom, and 
so on...so here's some more code I hope a few people will take the time to 
review :)

I'm coming from Python, so I figured one fairly simple thing I can do to 
ease the transition and get some practice working with O'Caml is to rewrite 
some of the more featureful python modules in O'Caml.  Here's an 
implementation of most of the useful (read: stuff I've used :)) functions 
from the Python "string" module.  Don't worry if you don't know Python or 
that module -- I've written an interface file that comments what each 
function is supposed to do.

Here are the files:


The one thing I think would be better done already is that the functions 
should probably take the string they're to operate on as their last 
argument, so new functions can be created more easily by partial function 

Anyway, if anyone does review this code, feel free to rip it apart -- I'm 
far more concerned with becoming a better O'Caml programmer than with 
keeping my pride :)


(PS: Sorry about the AOL links, but that's the ISP my family uses, and since 
I'm "en vacances" for the summer, it's what I'm stuck with :))
Get your FREE download of MSN Explorer at http://explorer.msn.com

Bug reports: http://caml.inria.fr/bin/caml-bugs  FAQ: http://caml.inria.fr/FAQ/
To unsubscribe, mail caml-list-request@inria.fr  Archives: http://caml.inria.fr