Delivered-To: garrigue at math.nagoya-u.ac.jp Authentication-Results: mailhost.math.nagoya-u.ac.jp sender=lablgtk-bounces at yquem.inria.fr; domainkey=neutral (no query protocol specified; no policy for yquem.inria.fr) Delivered-To: lablgtk at yquem.inria.fr DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:sender:subject:mime-version :content-type:from:in-reply-to:date:cc:content-transfer-encoding :message-id:references:to:x-mailer; bh=3YFsT24cC5w6cCg+MLaG17fJzUmPEPJnh+WCVUfPLes=; b=tDH5DzQOlUzTVGvrEjkkTWjXsGNFhPIOB8HNb2t3h3HAkXHtFUM8P3Hkx6ZyDlRRrQ aFPIv6vCZCrztSWwFyPBPamUU+2k2pAL5u6hhKNUxaWS47IqzR3A1bVTSrNhW4/Dp8Q+ +npEc/lzs9Dq/JhAT3hYorNGNlJvgTRbPhmo0= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=sender:subject:mime-version:content-type:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to:x-mailer; b=HMxpe5AlEKrOei0MEep7Sw14wU6op2CFfkbBNm0NxSBIhIjKhQFZrHk1pyiCAFhrgf 3IX+X3/PKajwDhOAcUuCThN0HIynxEMPs/wo1HO0z8guJiApXjzJdZDwUNDzN73Fg6B3 DSNfU2r4vJLYl2KV74LjIboleIeMM2UBiXUdE= Subject: Re: [Lablgtk] Type annotation (obviously) needed... Mime-Version: 1.0 (Apple Message framework v1082) Content-Type: text/plain; charset=us-ascii From: Jacques Garrigue In-Reply-To: Date: Sun, 12 Dec 2010 15:29:26 +0900 Content-Transfer-Encoding: quoted-printable Message-Id: <70EA64DB-0990-47D7-A5E2-50F95F872E89 at gmail.com> References: To: Serge Le Huitouze Cc: lablgtk Status: U As a general rule, when you call a method or do a coercion on a widget, its type should be known through an annotation.=20 (Of course, this is not needed in all cases, but when you get this kind of hard to understand error message, this is usually the case). Here the easiest point to annotate is in init_one: let init_one (msg, trvw, store, col : _ * GTree.view * = GTree.list_store * _) =3D This appears to be sufficient to solve your problem. Jacques On 2010/12/07, at 15:54, Serge Le Huitouze wrote: > Hi there, >=20 > I have a compilation error while compiling the attached program > [The command line is included at the beginning of the file. > In order to simplify compilation, I've inlined the glade-generated > code. Caution however: you still need the glade file to run the > program]. >=20 > The important part of the error message (I reproduce the complete > error message at the end of this email, but it's probably not > necessary for you, experts) goes like this: > * The universal variable 'e would escape its scope >=20 > If I comment out lines containing "store#append" and "store#set" > in function "indirect_way" (lines #82 and #83), I have no problem. > Also, note that similar calls in "direct_way" pose no compilation > problem. > So my problem obviously has to do with type wizardry, and a > type annotation should do the trick. > But I've no clue as what (and where) this annotation should be! >=20 > Can someone help me? >=20 > Thanks in advance. _______________________________________________ Lablgtk mailing list Lablgtk@yquem.inria.fr http://yquem.inria.fr/cgi-bin/mailman/listinfo/lablgtk