Re: [Vala] Delegates without target



Why "has_target" and not "has_user_data"?

Jürg Billeter wrote:
Callbacks in C libraries usually have a user_data parameter, which is
used by Vala to pass the object of an instance method. However, some
callbacks do not have a user_data parameter. Vala required bindings to
use the `static' modifier for the delegate to let the compiler know
about this limitation.

The `static' modifier for delegates has been deprecated now by

    [CCode (has_target = false)]

The rationale for the change can be found in bug 526549 [1]. The
`static' modifier still works, but the compiler will print a warning in
future versions when not using --enable-deprecated.

Jürg

[1] http://bugzilla.gnome.org/show_bug.cgi?id=526549

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



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