Re: [Vala] Support for custom attribute introspection/refle ction?



On Mon, 25 Apr 2011 10:27:16 +0100, Ricardo Gladwell wrote:
Hi Luca

My classes and functions are declared publicly in a shared library:


https://gitorious.org/vain/vain/blobs/master/vain-vala-plugin/Source/Main/Vala/ValaCompileExecutableGoal.vala

When I move my classes into the default namespace, GIR successfully
creates GIR introspection information.

--
Ricardo Gladwell <ricardo gladwell gmail com>
http://www.google.com/profiles/ricardo.gladwell
Twitter: @rgladwell - MSN: axonrg gmail com


On Mon, 2011-04-25 at 11:12 +0200, Luca Bruno wrote:
On Mon, Apr 25, 2011 at 10:08:56AM +0100, Ricardo Gladwell wrote:
> I'm trying to generate gir files for my project, but I only get XMl for > my functions and classes declared outside of my library namespace. Is
> this a known bug?

GIR is only for libraries exporting public API.


_______________________________________________
vala-list mailing list
vala-list gnome org
http://mail.gnome.org/mailman/listinfo/vala-list

GObject-Introspection does not support nested namespaces.

Here is a long discussion discussing what and why it was decided:
https://bugzilla.gnome.org/show_bug.cgi?id=576327

Nested namespace is what you have in your file.
Putting it in the global removes any nested namespaces and therefore it works.

For a gir, you normally have to put the code in the namespace that is
the same name as your package.

As of now the Vala compiler either ignores any nested namespaces, or just
generates improper gir code. (which generally causes
g-ir utilities to segfault)

--
Jonathan Ryan



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