Re: [Vala] Small syntax request labeled loops
- From: "Travis Watkins" <amaranth ubuntu com>
- To: "Dov Grobgeld" <dov grobgeld gmail com>
- Cc: vala-list gnome org
- Subject: Re: [Vala] Small syntax request labeled loops
- Date: Wed, 2 Jul 2008 13:14:26 -0500
2008/6/30 Dov Grobgeld <dov grobgeld gmail com>:
A small syntax enhancement borrowed from Perl that I would like to see in
vala is labeled loops, that can be referenced in continue and break
statements. Here is an example:
pixels:
while(foo) {
for (int i=0; i<1000; i++) {
if (a)
break pixels;
if (b)
continue pixels;
}
}
See the "last" and "next" statements of perl for a larger example.
Why not just ask for goto, that seems to be what you really want.
--
Travis Watkins
http://www.realistanew.com
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]