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
Re: [Caml-list] Type inference + optional parameters
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: brogoff@s...
Subject: Re: [Caml-list] Type inference + optional parameters
On Tue, 2 Sep 2003, Christoph Bauer wrote:
> Sorry, but what are the benefits of these functions over the original
> function without the optional parameter? 

None. I was being facetious, sorry. 

> I need a conversion function conv:'a -> 'b and the default value should be 
> the identity.

There is no suitable default suitable conversion function of that type (think 
about it for a minute and you'll understand), so there is no good way to make 
an optional argument of type ('a -> 'b). 

-- Brian

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