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] What are Classes for in O'Caml?
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2002-11-09 (02:55)
From: brogoff@s...
Subject: Re: [Caml-list] What are Classes for in O'Caml?
On Fri, 8 Nov 2002, Michael Wohlwend wrote:
> I got to ocaml two weeks ago and the first thing I realized was that due the 
> the functional programming style and the module system the need for 
> oo-programming is much lower than with imperative style languages (at least 
> for me).

I tend to use the class system to ameliorate the annoying limitations of 
OCaml records. You know, no overloaded field labels, functions can't be 
polymorphic over a set of labels, that kind of thing. I'd be thrilled if 
I could have all of this stuff in a record system and get pattern matching 

> Has somone found a *best* solution (for his tasks) to combine them (classes 
> und modules) or is it really just a matter of taste?

In addition to the O'Reilly book and Xavier's talk slides, take a gander at 
Didier Remy's APPSEM notes, where he discusses this issue in detail, and 
provides pointers to a symbolic algebra program which uses modules and 
classes together. 

-- Brian

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