Re: [Vala] Mixing C with vala



-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

On 09/23/2015 11:10 PM, rastersoft wrote:

Hi:

If I can do a sugestion, try to use Autovala to automagically 
generate cmake files. It allows to easily mix C and Vala too.

This might be a solution to the problem but i'm afraid it does not
help me understand what is actually happening.

I've prepared two gists to reproduce the problem.

The following is a gist that contains two vala-files. one containing
the main method. The other one containing a class that is being
instantiated from the main-method. This example works as you'd expect.

https://gist.github.com/grindhold/69aaa90e30bc130b7ae0

The second gist is a gist that contains a main.vala, and a
gereon-page.c and a gereon-page.h . those files are generated by vala
with the -C and -h-flags. Additionally there is a gereon.vapi that
describes the methods of Page towards the vala-compiler. This example
does not work beacause the unreferencing methods in the C-stage of
main.vala is "gereon_page_unref()" instead of "g_object_unref()". Why
is that?

https://gist.github.com/grindhold/f2a39dab2dd1c172b355

Thanks in advance. I'd really like to understand what happens.

Yours, Grindhold.



-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2

iQIcBAEBCAAGBQJWAyXqAAoJEBuqgJs6izSEPcYP/0nYc0EgI1EUZ314BmseW4lV
2wTyLAJZ0U4yWfyhHNt6lYfbcOvi3Q6SnvPRVU0BHSdENkHijGqP/BNj3QEys8z0
3MPr++adLAIiGm+wREAKUXqRYL/ogyP6D+Ag2KB6eQKkVraaRMhS/DvyMo0IVtNG
nYsV/sV5Jg+jMiZAo3/3zTjTgVOzAyj7M0yOPadPAO5X1YCdFk+RmesGs2CAYElo
AY5y9Tk/218V3p3FxLGUuoAf2S+Z+BqgEphxXiQKH+9sU20uv++pvDu7pfmEp5tU
l7GZyGUofPEXWvNu3jf6Nps4Pg0A7qtFQTLMMVUdbksZg9ILlwfl1E7hQSghkEoL
Hzr0ba4OjmygBpgJUo9Dm2zicinB/J3ktNBk3SYQ01Y5wWFSaNiSW+x3z097mwBS
03ZBKyc4JybgCXhEkTEJbu3lm+Jt/9/rbeIriSFRshNpcXKHSZcqkpvacUy+IjMF
VC4KrC5XgGb7ElBA9o9L98SwsTYpezqh+92m3qa5tcJA61QrT3rMkOg9GMeu7Jg9
jz+EQ5NgUaQ+5eBSIb/DXR4HDI0lc1WXzq+JE4fpL+KvAh957rT7NAaDOKRWmmT9
AN1RLPBRi17viOyQvUVV8A+CNSUbqJ2rdMzP05zYd7SPtwDlmoVc0zRac6QaRyXT
xRlje156WfIC0MncmYg7
=bWwB
-----END PGP SIGNATURE-----


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]