[Vala] JDBC-Pendant for vala?

2014-03-06 Thread Chr Landl
Hi, is there anything similar to JDBC, but for vala? JDBC is a java API that makes it easy (minimizes work on adaptation) to interchange different database drivers (MySQL, Postgres, SQlite, ...). That would save me a lot of work for my hobby (https://github.com/Titanl/jumpfree). Thanks in

[Vala] Arrays in generics

2014-03-06 Thread James Dean Palmer
Hi, I'm new to Vala and have run into an issue with generics and arrays. Consider this example: public class VectorT { internal T[] items; public Vector.from(T[] source) { } } This allows me to conveniently initialize the vector like this: new

Re: [Vala] JDBC-Pendant for vala?

2014-03-06 Thread Luca Dionisi
http://www.gnome-db.org/ On Mon, Feb 24, 2014 at 12:10 PM, Chr Landl clande...@gmail.com wrote: Hi, is there anything similar to JDBC, but for vala? JDBC is a java API that makes it easy (minimizes work on adaptation) to interchange different database drivers (MySQL, Postgres, SQlite, ...).

Re: [Vala] question Gtk 3 + gstreamer 1.0

2014-03-06 Thread Luca Bruno
On 06/03/2014 05:43, Michael Catanzaro wrote: On Thu, 2014-03-06 at 08:42 +0800, Nor Jaidi Tuah wrote: /home/flavio/Documentos/JAMediaSuite/UbuntuRadio/vala/UbuntuRadio.vala.c:377:2: warning: 'g_type_init' is deprecated (declared at /usr/include/glib-2.0/gobject/gtype.h:669)

Re: [Vala] Arrays in generics

2014-03-06 Thread Luca Bruno
On 05/03/2014 20:36, James Dean Palmer wrote: Hi, I'm new to Vala and have run into an issue with generics and arrays. Consider this example: public class VectorT { internal T[] items; public Vector.from(T[] source) { } } This allows me to conveniently

Re: [Vala] Inheriting from GLib.Action

2014-03-06 Thread Luca Bruno
On 06/03/2014 06:08, Edward Hennessy wrote: Thank you for the help. I'm suspicious of the following code snippet in valagirparser.vala starting at line 920: prop.set_attribute (NoAccessorMethod, false); if (prop.get_accessor != null) { var m = getter != null ? getter.symbol as Method

Re: [Vala] question Gtk 3 + gstreamer 1.0

2014-03-06 Thread Nor Jaidi Tuah
On Wed, 2014-03-05 at 23:53 -0800, Evan Nemerson wrote: a very long and illuminating answer. Thanks for the reply. Your time makes vala not just a great language, but a great community as well. Nice day Nor Jaidi Tuah PRIVILEGED/CONFIDENTIAL information may be contained in this

Re: [Vala] array memory leak?

2014-03-06 Thread Ulink
Am 06.03.2014 01:07, schrieb Nor Jaidi Tuah: Most probably it's the optimizing behaviour of the memory allocator and has got nothing to do with the vala compiler. I don't think this is the case. If you call Dummy2(20), after returning from this function there are approximately 60MB of RAM

Re: [Vala] array memory leak?

2014-03-06 Thread Ulink
Am 05.03.2014 23:01, schrieb Steven Oliver: What version libgee are you using? The one installed with Ubuntu saucy (13.10): 0.8.2 (dpkg says) Anyway, valac which saucy uses is not that old (0.20.1) and my Dummy() functions shows the memory leak with standard vala arrays (no gee involved here I

Re: [Vala] array memory leak?

2014-03-06 Thread Luca Bruno
On 06/03/2014 09:59, Ulink wrote: I don't think this is the case. If you call Dummy2(20), after returning from this function there are approximately 60MB of RAM already used until the program ends. Say LOOPS is 100.000.000 instead of 1.000.000 there are 6GB lost and my PC starts massive

Re: [Vala] array memory leak?

2014-03-06 Thread Jürg Billeter
On Wed, 2014-03-05 at 19:17 +0100, Ulink wrote: Consider the following (dummy) functions which shows memory leaks here (valac 0.20.1 on ubuntu saucy 64Bit). It seems the problem exists with Gee.ArrayList too. May someone confirm this? According to valgrind 3.9.0, there are no leaks with this

Re: [Vala] array memory leak?

2014-03-06 Thread Ulink
Hi Juerg, According to valgrind 3.9.0, there are no leaks with this test code on my system (up-to-date Linux on x86-64). I've tested with valac 0.20.1 and valac 0.22.1. Confirmed, valgrind shows no memory leak. I'm puzzled. void Dummy1(int len) { const int LOOPS=100; string[] dummy =