Re: [Vala] Patch: libgee:get_weak_ref

2008-11-21 Thread Yu Feng
On Fri, 2008-11-21 at 21:03 +0100, Jürg Billeter wrote: > On Fri, 2008-11-21 at 02:59 -0500, Yu Feng wrote: > > On Wed, 2008-11-19 at 18:26 -0500, Yu Feng wrote: > > > When the collections in Gee are holding strong references, it is > > > difficult to obtain a weak reference to the elements in the

[Vala] Chaining up constructors.

2008-11-21 Thread Yu Feng
Dear Jurg and others, I have an idea about chaining up constructors to share with you. Situation We have 2 different constructors, the construction block(CB), and the construct function(CF). for GType based classes, CB doesn't work, chaining up CF works. for GObject based classes, CB wo

Re: [Vala] Patch: libgee:get_weak_ref

2008-11-21 Thread Yu Feng
On Fri, 2008-11-21 at 21:03 +0100, Jürg Billeter wrote: > On Fri, 2008-11-21 at 02:59 -0500, Yu Feng wrote: > > On Wed, 2008-11-19 at 18:26 -0500, Yu Feng wrote: > > > When the collections in Gee are holding strong references, it is > > > difficult to obtain a weak reference to the elements in the

Re: [Vala] Patch: libgee:get_weak_ref

2008-11-21 Thread Jürg Billeter
On Fri, 2008-11-21 at 02:59 -0500, Yu Feng wrote: > On Wed, 2008-11-19 at 18:26 -0500, Yu Feng wrote: > > When the collections in Gee are holding strong references, it is > > difficult to obtain a weak reference to the elements in the container. > > > > The situation is: > > > > class Node { > >

Re: [Vala] ArrayList sort function

2008-11-21 Thread Daniel Lucraft
I cleaned up the comparison functions a bit after playing with Vala pointers and begging on IRC. best Dan ___ Daniel Lucraft http://www.daniellucraft.com/ 2008/11/21 Daniel Lucraft <[EMAIL PROTECTED]>: > As requested on IRC, here are two patches that add a sort method to

Re: [Vala] other problems building wizbit

2008-11-21 Thread Jürg Billeter
On Fri, 2008-11-21 at 13:45 +, Karl Lattimer wrote: > On Fri, 2008-11-21 at 14:30 +0100, Jürg Billeter wrote: > > On Fri, 2008-11-21 at 13:20 +, Karl Lattimer wrote: > > > On Fri, 2008-11-21 at 14:11 +0100, Jürg Billeter wrote: > > > > On Fri, 2008-11-21 at 12:46 +, Karl Lattimer wrote:

[Vala] ArrayList sort function

2008-11-21 Thread Daniel Lucraft
As requested on IRC, here are two patches that add a sort method to ArrayList. Some notes: 1. I wasn't sure where to put the vapi binding to the C stdlib function qsort. But I saw that glib.vapi had the reference to the strcmp function so I put it next to that. 2. There are two comparison fu

Re: [Vala] other problems building wizbit

2008-11-21 Thread Karl Lattimer
On Fri, 2008-11-21 at 14:30 +0100, Jürg Billeter wrote: > On Fri, 2008-11-21 at 13:20 +, Karl Lattimer wrote: > > On Fri, 2008-11-21 at 14:11 +0100, Jürg Billeter wrote: > > > On Fri, 2008-11-21 at 12:46 +, Karl Lattimer wrote: > > > > After overcoming my previous issues I'm now running int

Re: [Vala] other problems building wizbit

2008-11-21 Thread Jürg Billeter
On Fri, 2008-11-21 at 13:20 +, Karl Lattimer wrote: > On Fri, 2008-11-21 at 14:11 +0100, Jürg Billeter wrote: > > On Fri, 2008-11-21 at 12:46 +, Karl Lattimer wrote: > > > After overcoming my previous issues I'm now running into some other > > > problems. > > > > > > Again any help much ap

Re: [Vala] other problems building wizbit

2008-11-21 Thread Karl Lattimer
On Fri, 2008-11-21 at 14:11 +0100, Jürg Billeter wrote: > On Fri, 2008-11-21 at 12:46 +, Karl Lattimer wrote: > > After overcoming my previous issues I'm now running into some other > > problems. > > > > Again any help much appreciated. > > This looks like a vala-independent libtool issue. Po

Re: [Vala] other problems building wizbit

2008-11-21 Thread Jürg Billeter
On Fri, 2008-11-21 at 12:46 +, Karl Lattimer wrote: > After overcoming my previous issues I'm now running into some other > problems. > > Again any help much appreciated. This looks like a vala-independent libtool issue. Possibly using libtool 2 without clean autogen? Can you try again after

[Vala] other problems building wizbit

2008-11-21 Thread Karl Lattimer
After overcoming my previous issues I'm now running into some other problems. Again any help much appreciated. /bin/sh ../libtool --tag=CC --mode=compile gcc -DHAVE_CONFIG_H -I. -I.. -I..-I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/gio-unix-2.0/ -I/usr/include/uuid

Re: [Vala] Upgrade to vala 0.5 problems with gobject

2008-11-21 Thread Karl Lattimer
On Fri, 2008-11-21 at 13:03 +0100, Jürg Billeter wrote: > On Fri, 2008-11-21 at 11:47 +, Karl Lattimer wrote: > > I've just upgraded to vala 0.5 and when I attempt to build something I > > get a large stream of gobject errors which look a bit overly verbose? > > > > Here's a dump of them... >

Re: [Vala] Upgrade to vala 0.5 problems with gobject

2008-11-21 Thread Jürg Billeter
On Fri, 2008-11-21 at 11:47 +, Karl Lattimer wrote: > I've just upgraded to vala 0.5 and when I attempt to build something I > get a large stream of gobject errors which look a bit overly verbose? > > Here's a dump of them... > > Any ideas? I'm assuming that you're trying to build wizbit. Th

[Vala] Upgrade to vala 0.5 problems with gobject

2008-11-21 Thread Karl Lattimer
I've just upgraded to vala 0.5 and when I attempt to build something I get a large stream of gobject errors which look a bit overly verbose? Here's a dump of them... Any ideas? gobject-2.0.vapi:372.3-372.26: error: `GLib.Signal' already contains a definition for `query' public st

Re: [Vala] Some more troubles with GValues

2008-11-21 Thread Sudharshan S
On Wednesday 12 November 2008 23:03:56 Daniele Benucci wrote: > > First try: > (1)HashTable properties = server.GetProperties(); > (2)string address = properties.lookup("Address").get_string(); > Vala compilation is successful, but C compilation fails with "incompatible > ty

Re: [Vala] Foreach on interfaces

2008-11-21 Thread Spencer, Matthew
Thanks for the feedback, that has fixed the problem. Matt -Original Message- From: Jürg Billeter [mailto:[EMAIL PROTECTED] Sent: Fri 11/21/2008 10:10 AM To: Spencer, Matthew Cc: vala-list@gnome.org Subject: Re: [Vala] Foreach on interfaces Hi Matt, On Fri, 2008-11-21 at 09:48 +, S

Re: [Vala] Foreach on interfaces

2008-11-21 Thread Jürg Billeter
Hi Matt, On Fri, 2008-11-21 at 09:48 +, Spencer, Matthew wrote: > But I get errors: > error: missing class prerequisite for interface 'InterfaceA' > on the lines marked with 1 and 2. Interfaces need to have a class as prerequisite to be usable as a variable - we miss memory management infor

[Vala] Foreach on interfaces

2008-11-21 Thread Spencer, Matthew
Hi All I was surprised to find that the following does not work under vala 0.5.1 public interface InterfaceA { public abstract void function(); } public class Instance : InterfaceA { public void function() { } } public static main(string[] args) { List list=new List(); // 1 list.