On Fri, Jan 18, 2002 at 08:03:41PM -0800, Larry Wall wrote:
> : allow this:
> :
> : File.foreach('/usr/dict/words') { print }
>
> File.foreach('/usr/dict/words', { print })
>
> or even (presuming the prototype is available for parsing):
>
> File.foreach '/usr/dict/words' { print }
Hi all,
I have just one syntatic wish for Apoc4 (which in all other points I
find utterly fantastic).
Could we have:
foreach $item in @arr {...}
Instead of
foreach @arr -> $item {...}
I find the first one:
- Much more pleasent to the eyes and less noisy on a long program.
- Easie
Sorry for the 4 times posts, i was testing a new mail program and it
didn't prove too good.
Now i feel so ashamed :-[
-angel
> "Angel" == Angel Faus <[EMAIL PROTECTED]> writes:
Angel> Hi all,
Angel> I have just one syntatic wish for Apoc4 (which in all other points I
Angel> find utterly fantastic).
Angel> Could we have:
Angel> foreach $item in @arr {...}
Angel> Instead of
Angel> foreach @arr -> $item {...}
L
The two current examples of an evil expression block are do {} and eval {},
which require a semicolon terminator. However, with eval {} leaving, that
leaves just do {}, which does (or should) fall more in line of thinking of
grep {}, map {}, and sort {}: the other expression blocks. For do {}
Interestingly, this one tweak to the whitespace rule also means that we'll
be able to simplify the parentheses out of other similar built-in constructs:
if $foo { ... }
elsif $bar { ... }
else { ... }
while $more { ... }
for 1..10 { ... }
I think throwing out two required
No examples are given, but are we to assume that this:
for ($x = 0; $x < 100; $x++) {
...
}
becomes this:
loop $x=0; $x < 100; $x++ {
...
}
How would you use an $x lexically scoped to the loop block?
Most of the other constructs seem to be using a '-> $x' constr
Why the double semantics of 'when'?
It implicitly breaks when used as a 'when' block, but does not as a 'when'
statement. It seems that a when should be a when should be a when, and a
when being a when would be a win.
The example given:
given $x {
warn("Odd value")when
On Fri, 18 Jan 2002 12:33:48 -0500, Will Coleda wrote:
>http://www.perl.com/pub/a/2002/01/15/apo4.html
>
>David Whipp wrote:
>>
>> Michael G Schwern wrote:
>>
>> > Reading this in Apoc 4 ...
>>
>> I looked on http://dev.perl.org/perl6/apocalypse/: no sign of Apoc4. Where
>> do I find this late
You're treating do, if, foreach as if they were keywords. I'm not
entirely sure that that's still the case. And you're also forgetting
the possibility of user implemented control type operators/methods.
Unless I'm very much mistaken you're suggesting that we special case
the parser for 'do' and a
On Saturday 19 January 2002 12:24, Piers Cawley wrote:
> You're treating do, if, foreach as if they were keywords. I'm not
> entirely sure that that's still the case.
'do' perhaps. But not really. And it's irrelevant to my argument.
> And you're also forgetting
> the possibility of user imple
* Bart Lateur ([EMAIL PROTECTED]) [20 Jan 2002 03:56]:
> On Fri, 18 Jan 2002 12:33:48 -0500, Will Coleda wrote:
> > http://www.perl.com/pub/a/2002/01/15/apo4.html
[...]
> I thought I had just missed it... but there's no trace of it in the
> archives of <[EMAIL PROTECTED]>. Or any other perl6 list.
On Saturday 19 January 2002 12:20, iain truskett wrote:
> * Bart Lateur ([EMAIL PROTECTED]) [20 Jan 2002 03:56]:
> > On Fri, 18 Jan 2002 12:33:48 -0500, Will Coleda wrote:
> > > http://www.perl.com/pub/a/2002/01/15/apo4.html
>
> [...]
>
> > I thought I had just missed it... but there's no trace of
At 1:14 PM -0500 1/19/02, Bryan C. Warnock wrote:
>On Saturday 19 January 2002 12:20, iain truskett wrote:
>> * Bart Lateur ([EMAIL PROTECTED]) [20 Jan 2002 03:56]:
>> > On Fri, 18 Jan 2002 12:33:48 -0500, Will Coleda wrote:
>> > > http://www.perl.com/pub/a/2002/01/15/apo4.html
>>
>> [...]
>>
This just popped up from my sig file:
Plus I remember being impressed with Ada because you could write an
infinite loop without a faked up condition. The idea being that in Ada
the typical infinite loop would be normally be terminated by detonation.
-- Larry Wall in <[EMA
Is this list of special blocks complete and correct?
BEGIN Executes at the beginning of compilation
CHECK Executes at the end of compilation
INITExecutes at the beginning of run
END Executes at the end of run
On Saturday 19 January 2002 22:05, Brent Dax wrote:
> Is this list of special blocks complete and correct?
>
> BEGIN Executes at the beginning of compilation
> CHECK Executes at the end of compilation
> INITExecutes at the beginning of run
>
> On Saturday 19 January 2002 22:05, Brent Dax wrote:
> > Is this list of special blocks complete and correct?
> >
> > BEGIN Executes at the beginning of compilation
> > CHECK Executes at the end of compilation
> > INIT Executes at the beginning of run
> > END Executes at the end of run
> > PRE Ex
18 matches
Mail list logo