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
method name collision ?
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2004-12-25 (19:53)
From: briand@a...
Subject: method name collision ?

I'm getting the following error 

The method point has type 'a -> 'b but is expected to have type
  x:int -> y:int -> unit

for this code :

method point p0 =

The error makes sense, as in, I know that it is colliding with a
method defined in the drawable class.

However I am inheriting the class using :

  inherit GDraw.drawable ?colormap w as drawable

It seems to me that the method I am defining, self#point, and the
method in drawable, i.e. drawable#point, are distinct and therefore
I should not be seeing this error message ?

Can someone enlighten me ?