Re: [Vala] [ModuleInit] and __attribute__ ((constructor)) ?
- From: Jürg Billeter <j bitron ch>
- To: Ildar Mulyukov <ildar users sourceforge net>
- Cc: Vala compiler development and discussion <vala-list gnome org>
- Subject: Re: [Vala] [ModuleInit] and __attribute__ ((constructor)) ?
- Date: Fri, 12 Dec 2008 09:04:51 +0100
Hi Ildar,
On Wed, 2008-10-15 at 03:03 +0600, Ildar Mulyukov wrote:
I am very new to Vala. Great thanks to Jürg and participants.
I've a question (or it's really two separate questions?)
1. What does [ModuleInit] do?
I've checked the generated C-code for it and found that it does
nothing noticeable. At least in this snippet:
http://live.gnome.org/Vala/TypeModules
Vala uses g_type_module_register_type if you add the [ModuleInit]
attribute. That's needed if you want to dynamically load and unload
plug-ins that define types in the GObject type system.
2. I want to have __attribute__ ((constructor)) function but cannot
figure out how to do it. Any hint?
We do not support this at the moment. It's only available in GCC, as
fars as I know.
Jürg
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]