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 638797 - Vala miscompiles GLib.FileUtils.get_data
Vala miscompiles GLib.FileUtils.get_data
Status: RESOLVED OBSOLETE
Product: vala
Classification: Core
Component: Code Generator
0.10.x
Other Linux
: Normal normal
: ---
Assigned To: Vala maintainers
Vala maintainers
Depends on:
Blocks:
 
 
Reported: 2011-01-06 08:38 UTC by W. Michael Petullo
Modified: 2011-04-22 14:03 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Vala source that fails to compile (3.33 KB, text/plain)
2011-01-06 08:39 UTC, W. Michael Petullo
Details
Corresponding C source (25.86 KB, text/plain)
2011-01-06 08:40 UTC, W. Michael Petullo
Details

Description W. Michael Petullo 2011-01-06 08:38:13 UTC
Vala 0.10.2 seems to miscompile some code that uses GLib.FileUtils.get_data. This results in the following failure from gcc:

vala-dpap-record.c:217:2: error: ‘this’ undeclared (first use in this function)
vala-dpap-record.c:217:2: note: each undeclared identifier is reported only once for each function it appears in
vala-dpap-record.c:218:2: warning: statement with no effect

I have attached the Vala and C source. I am compiling to C using:

/usr/bin/valac --vapidir=../vala --pkg gee-1.0 --pkg gtk+-2.0 --pkg gstreamer-0.10 --pkg libdmapsharing-3.0 --pkg libsoup-2.4 --pkg glib-2.0 dpapview.vala vala-dmap-db.vala vala-dpap-record.vala -C

Vala 0.11.3 does not have this problem.
Comment 1 W. Michael Petullo 2011-01-06 08:39:35 UTC
Created attachment 177633 [details]
Vala source that fails to compile
Comment 2 W. Michael Petullo 2011-01-06 08:40:40 UTC
Created attachment 177634 [details]
Corresponding C source
Comment 3 Luca Bruno 2011-04-22 14:03:09 UTC
Vala 0.12 has been released, the bugfix isn't going to be backported to 0.10. Closing as obsolete, thanks for taking time to report the bug.