Re: [gtk-list] Re: auto-generating language bindings



Marius Vollmer <mvo@zagadka.ping.de> wrote,

> "Manuel M. T. Chakravarty" <chak@is.tsukuba.ac.jp> writes:
> 
> > Marius Vollmer <mvo@zagadka.ping.de> wrote,
> > 
> > > All necessary information about signals can be found at run-time.  If
> > > that is not good enough, you are very welcome to add signal
> > > information to the defs files.  I can give you some hints how to do
> > > that in the `right' way.
> > 
> > It appears to me that the language bindings so far focus on
> > languages that have a rather weak *static* type system (Guile, Perl,
> > Python)
> 
> Why do you think Guile has a weak static type system?  In my books, it
> has the full blown dynamic type thing going.  

Maybe I should be more precise.  The type system of Guile
prevents a compiler from statically (ie, at compile time)
inferring much information about types.  Instead, most of
the type checks are handled at runtime, ie, are dynamic.  (I
don't say this is bad, it is just the way Guile is
designed.)  Naturally, a strongly typed language (ie, one
where each expression has a unique type that can be
determined by a compiler at compile time) has a richer
interface language, because an interface has to include a
lot of static type information.

> But you are right that
> the formal description is geared towards such dynamic languages.  That
> doesn't mean its unusable; it just needs work.

I didn't want to imply that it is unusable.  I just meant to 
say that a lot more information is needed to generate a
binding for a language with a strong type system.
Unfortunately, this is not only a question of the amount of
information, but also requires to think about a language
independent way to describe this additional information
(which IMHO is not easy) - certainly a challenging task.

Cheers,

Manuel



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