On Tue, Sep 01, 2009 at 06:17:43 -0400, Arc Riley wrote:
> There is a lot more than a vapi needed for this.
>
> First, there is a big difference between using Python to extend Vala and
> Vala to extend Python. I assume what we are talking about here is building
> Python extension modules in the Vala language
The OP does not seem to be. He says "like the example for Lua" and that shows
running lua code from vala.
> The vapi is of course needed, but more than this valac needs to be aware of
> the Python object model - which will take either a fork of valac or a plugin
> architecture added to valac. There's been no recent word on plugin support
> for valac so our current effort is a fork/branch of valac with the necessary
> PyType/PyObject handling added.
Vala does not need to understand python types (natively) either to create
python extension modules nor to call python.
For creating extension modules, python already knows how to wrap the glib
types by virtue of python-glib bindings. Moreover, there seem to be
experimental bindings using the gobject-introspection and when that works,
any vala library is a python extension module, instanteously, with no
additional effort.
For calling python code, the GLib type system is perfectly capable of
manipulating foreign objects if appropriate boxing conversions are defined,
so vapi for the python library is enough (obviously the stuff defined in
python will have to be called using dynamic API, because vala cannot be
dynamic itself).
--
Jan 'Bulb' Hudec <[email protected]>
_______________________________________________
Vala-list mailing list
[email protected]
http://mail.gnome.org/mailman/listinfo/vala-list