GNOME Bugzilla – Bug 577620
low-level delegate generation crashes vala
Last modified: 2010-03-26 17:23:00 UTC
test case: class xyz { void func () { } void a (GLib.Object obj) { Signal.connect (obj, "my_signal", func, null); } } fails with this assertion: ERROR:arraylist.c:177:gee_array_list_real_get: assertion failed: (_tmp0) which is really an access-out-of-bounds-index-in-array error. backtrace includes:
+ Trace 214086
and the region in the .vala code responsible: if (m.binding == MemberBinding.INSTANCE) { CCodeExpression arg; if (d.has_target) { arg = new CCodeIdentifier ("self"); } else { // use first delegate parameter as instance arg = new CCodeIdentifier ((d_params.get (0).ccodenode as CCodeFormalParameter).name); problem, of course, is that the func() function doesn't have a parameter #0.
I'm seeing something like this with valac 0.7.9, when using a local delegate declaration. > ERROR:arraylist.c:320:vala_array_list_real_get: assertion failed: ((index >= 0) && (index < self->priv->_size)) The backtrace looks like:
+ Trace 219962
Thanks for taking the time to report this bug. This particular bug has already been reported into our bug tracking system, but we are happy to tell you that the problem has already been fixed. It should be solved in the next software version. You may want to check for a software upgrade. *** This bug has been marked as a duplicate of bug 592769 ***