values should start with a low case char: EmptyGraph -> emptyGraph, AddNode -> addNode

Le 7 oct. 11 à 12:57, Walter Cazzola a écrit :

Dear all,
sorry for being so dumb but I've still problems with types and the sig
syntax.

I'm trying to write a Graph ADT:

module type GraphADT =
  sig
     type 'a graph
     val EmptyGraph : 'a graph

     val AddNode : 'a * 'a graph -> 'a graph
  end;;

but when I try to evaluate it I get:

Syntax error: 'end' expected, the highlighted 'sig' might be unmatched

pointing to the row inbetween type and the first val but I don't
understand why and how to solve it.

Any help is welcome as always

TIA
Walter
--

--
Caml-list mailing list.  Subscription management and archives:
https://sympa-roc.inria.fr/wws/info/caml-list
Beginner's list: http://groups.yahoo.com/group/ocaml_beginners
Bug reports: http://caml.inria.fr/bin/caml-bugs




--
Caml-list mailing list.  Subscription management and archives:
https://sympa-roc.inria.fr/wws/info/caml-list
Beginner's list: http://groups.yahoo.com/group/ocaml_beginners
Bug reports: http://caml.inria.fr/bin/caml-bugs

Reply via email to