After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 565872 - Criticals when using stacked arrays and D-Bus
Criticals when using stacked arrays and D-Bus
Status: RESOLVED FIXED
Product: vala
Classification: Core
Component: D-Bus
unspecified
Other All
: Normal normal
: ---
Assigned To: Vala maintainers
Vala maintainers
Depends on:
Blocks:
 
 
Reported: 2008-12-28 16:40 UTC by Philip Van Hoof
Modified: 2010-10-16 13:41 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Vala source (2.43 KB, text/plain)
2008-12-28 16:40 UTC, Philip Van Hoof
Details
Generated C source .c file (30.72 KB, text/x-csrc)
2008-12-28 16:41 UTC, Philip Van Hoof
Details
Generated C source .h file (3.30 KB, text/x-chdr)
2008-12-28 16:41 UTC, Philip Van Hoof
Details

Description Philip Van Hoof 2008-12-28 16:40:16 UTC
Will attach .c, .h and .vala files

pvanhoof@tinc:~$ /opt/vala/bin/valac --pkg dbus-glib-1 -o dbustest ./xesam2.vala

** (valac:21748): CRITICAL **: vala_ccode_binary_expression_construct: assertion `r != NULL' failed

** (valac:21748): CRITICAL **: vala_ccode_binary_expression_construct: assertion `r != NULL' failed

** (valac:21748): CRITICAL **: vala_ccode_binary_expression_construct: assertion `r != NULL' failed

** (valac:21748): CRITICAL **: vala_ccode_binary_expression_construct: assertion `r != NULL' failed
xesam2.c: In function ‘_main’:
xesam2.c:730: error: ‘fields’ undeclared (first use in this function)
xesam2.c:730: error: (Each undeclared identifier is reported only once
xesam2.c:730: error: for each function it appears in.)
xesam2.c:730: error: ‘false’ undeclared (first use in this function)
xesam2.c:730: error: ‘out’ undeclared (first use in this function)
xesam2.c:730: error: expected ‘;’ before ‘hit_count’
xesam2.c:730: error: expected statement before ‘)’ token
xesam2.c:730: error: expected expression before ‘/’ token
error: cc exited with status 256
Compilation failed: 1 error(s), 0 warning(s)
pvanhoof@tinc:~$ /opt/vala/bin/valac -C --pkg dbus-glib-1 -o dbustest ./xesam2.vala

** (valac:21764): CRITICAL **: vala_ccode_binary_expression_construct: assertion `r != NULL' failed

** (valac:21764): CRITICAL **: vala_ccode_binary_expression_construct: assertion `r != NULL' failed

** (valac:21764): CRITICAL **: vala_ccode_binary_expression_construct: assertion `r != NULL' failed

** (valac:21764): CRITICAL **: vala_ccode_binary_expression_construct: assertion `r != NULL' failed
pvanhoof@tinc:~$
Comment 1 Philip Van Hoof 2008-12-28 16:40:43 UTC
Created attachment 125434 [details]
Vala source
Comment 2 Philip Van Hoof 2008-12-28 16:41:06 UTC
Created attachment 125435 [details]
Generated C source .c file
Comment 3 Philip Van Hoof 2008-12-28 16:41:26 UTC
Created attachment 125436 [details]
Generated C source .h file
Comment 4 Philip Van Hoof 2008-12-28 16:43:25 UTC
By looking at the C source it looks like the comments that I added didn't get ignored.

Might not be related to the DBus support, but might be more related to the commented part of the line in the .vala file.
Comment 5 Jürg Billeter 2009-01-04 22:38:06 UTC
This issue is caused by stacked arrays in D-Bus methods.
Comment 6 Jürg Billeter 2010-10-16 13:41:07 UTC
commit cc435dd6ec069b87e986fa454e80e5fe80a0df72
Author: Jürg Billeter <j@bitron.ch>
Date:   Sat Oct 16 15:17:23 2010 +0200

    Report error when trying to use stacked arrays
    
    Stacked array support was never completed. Report an error instead of
    generating incorrect C code.
    
    Fixes bug 546603, bug 548428, bug 548429, bug 565865, bug 565872,
    bug 571322, bug 572649, and bug 576611.