Version française
Home     About     Download     Resources     Contact us    
Browse thread
[Caml-list] Doubt about function delaration parameter
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: David Allsopp <dra-news@m...>
Subject: RE: [Caml-list] Doubt about function delaration parameter
sieira wrote:
> Thanks for your replies. I'm now having some issue with Raphael's
> suggestion of using (string * string) list;; as the menu type.
> 
> 
> type menu = (string*string) list;;
> 
> Results in a syntax error at the first parenthesis, while
> 
> type menu = string*string;;
> 
> fails too (at the asterisk)
> 
> It seems like I'm missing something. Since according to the
> http://caml.inria.fr/pub/docs/manual-caml-light/node3.5.html
> documentantion , this sintax should be right.
> 
> I'm using Camllight 0.81 by François Boisson running in Ubuntu lucid lynx

People on this list will reasonably assume you're using Objective Caml unless you say otherwise - this should have been at the top of your original post. I don't know and don't have access to an installation of caml light but looking at http://caml.inria.fr/pub/docs/manual-caml-light/node3.9.html it would appear to me as though type abbreviations (which is what you're doing) need == in Caml Light:

type menu == (string*string) list;;

... but I may well be wrong.


David