Re: [Vala] anonymous functions
- From: Sam Liddicott <sam liddicott com>
- To: vala-list gnome org
- Subject: Re: [Vala] anonymous functions
- Date: Tue, 15 Jul 2008 10:20:46 +0100
* Sam Liddicott wrote, On 15/07/08 10:15:
I find this notation ugly:
notify += (s, p) => {
stdout.printf("property `%s' has changed!\n",
p.name);
};
Is there a reason why the => should be required?
notify += (s, p) {
stdout.printf("property `%s' has changed!\n",
p.name);
};
seems a lot more natural, all that's missing is the name cos there isn't
one...
Does the => signifiy anything particular?
And in the advanced example:
http://live.gnome.org/Vala/AdvancedSample
what does the s signify in
this.foo += s => {
stdout.printf ("Lambda expression %s!\n", name);
};
Thanks
Sam
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]