[Vala] Safe call operator

2012-01-31 Thread Artem Tarasov
Hello, today I stumbled upon this page: http://confluence.jetbrains.net/display/Kotlin/Null-safety There's so-called 'safe call operator' in Kotlin programming language which, when used in chains, resembles 'Maybe' monad from Haskell. Thus it makes easier to work with nullable types in some

Re: [Vala] Safe call operator

2012-01-31 Thread jim
Do you know the reason why it was rejected? I searched for more information but could only find the proposals, not the rejection. A null-safe operator (an elvis operator) seems like a natural complement to the nullable operator already in Vala. -- Jim On Tue, Jan 31, 2012 at 4:58 AM, Luca

[Vala] [ANNOUNCE] Vala 0.14.2 - Compiler for the GObject type system

2012-01-31 Thread Jürg Billeter
We are pleased to announce version 0.14.2 of Vala, a compiler for the GObject type system. Vala 0.14.2 is now available for download at: http://download.gnome.org/sources/vala/0.14/ Changes since 0.14.1 * Add libnl-3.0 bindings. * Add packagekit-glib2 bindings. * Add xtst bindings. * Many

Re: [Vala] Safe call operator

2012-01-31 Thread Luca Bruno
On Tue, Jan 31, 2012 at 3:32 PM, j...@yorba.org wrote: Do you know the reason why it was rejected? I searched for more information but could only find the proposals, not the rejection. http://blogs.oracle.com/darcy/entry/project_coin_final_five -- www.debian.org - The Universal Operating

Re: [Vala] Safe call operator

2012-01-31 Thread Artem Tarasov
As a starter, Java rejected that syntax. Yeah, but in Java at least a NullPointerException is thrown when null dereferencing occurs. In Vala the only option to provide null-safety is explicit checking for null after each method call in a chain. ___

[Vala] How to use GLib.Signal.connect?

2012-01-31 Thread Pete Fotheringham
I am working with Vala and GtkOSXApplication on Mac OS. I am using Vala 0.12 because I need to use dbus-glib and, as I understand it, this is not supported by versions of Vala beyond 0.12.1 I need to connect to a Mac Specific mac-specific NSApplicationOpenFile signal, which is generated by

Re: [Vala] How to use GLib.Signal.connect?

2012-01-31 Thread Luca Bruno
On Tue, Jan 31, 2012 at 4:53 PM, Pete Fotheringham pete.fothering...@codethink.co.uk wrote: I am working with Vala and GtkOSXApplication on Mac OS. I am using Vala 0.12 because I need to use dbus-glib and, as I understand it, this is not supported by versions of Vala beyond 0.12.1 I need to

Re: [Vala] How to use GLib.Signal.connect?

2012-01-31 Thread Pete Fotheringham
On 31/01/2012 17:09, Luca Bruno wrote: snip Can anyone give me an example of how to use Signal.connect() or suggest an alternative method? Cast (Callback)this.open_file_callback Thanks Luca, that worked - the line is now Signal.connect(osxApp, NSApplicationOpenFile,