Delivered-To: lablgtk at yquem.inria.fr To: lablgtk at math.nagoya-u.ac.jp From: Dawid Toton Date: Sat, 08 Sep 2007 13:44:08 +0200 Lines: 27 Message-ID: References: <20070906.091510.113010632.garrigue@math.nagoya-u.ac.jp> Mime-Version: 1.0 Content-Transfer-Encoding: 8bit In-Reply-To: <20070906.091510.113010632.garrigue at math.nagoya-u.ac.jp> Subject: [Lablgtk] Re: No destroy signal? Content-Type: text/plain; charset=windows-1252; format=flowed Content-Length: 1423 Jacques Garrigue pisze: > From: Dawid Toton > > >> I've compiled current SVN version of LablGTK with Cygwin+mingw. >> When compiling hello.ml from LablGTK tutorial I get this message: >> >> window#connect#destroy ~callback:destroy; >> ^^^^^^^^^^^^^^ >> This expression has type GContainer.container_signals >> It has no method destroy >> > > After checking, here is the explanation: for whatever reason, you haveno gContainer.cmi in your library path (but you have at leastgMain.cmi, gButton.cmi and gWindow.cmi, otherwise nothing would work). > Thanks a lot! You're right. Now it copiles and works. The reason for the mess: I have just some files copied by hand (in order to satisfy ocamlbuild, which is seriously confused by Windows environment). > In that case, the ocaml compiler assumes that > GContainer.container_signals is an abstract type, hence the above > error message, which could probably be improved. > I'm sometimes wondering whether this behaviour is correct... I think there are 2 issues with the compiler: 1) instead of saying "It has no method destroy" it should express it like this: "The method destroy is abstract" 2) in such cases it should at least show a warning: "File ….cmi not found, assuming sth and sth..." Dawid Toton _______________________________________________ Lablgtk mailing list Lablgtk@yquem.inria.fr http://yquem.inria.fr/cgi-bin/mailman/listinfo/lablgtk