At 07:33 PM 8/3/00 +0200, Bart Lateur wrote: >On 03 Aug 2000 06:39:02 -0700, Randal L. Schwartz wrote: > > >>> We have one. It's called "comma in a scalar context". :) > > > >Bart> Now do the same with a print command. > > > > print("This stuff gets"," printed", "\n"), return 3 > > if $some_condition; > >Somebody please please tell me why this doesn't generate a warning à la >"print used as a function". I was expecting that. Your instincts are correct; just need to put that -w in :-) $ perl -Mstrict -we 'sub foo {print ("This stuff gets"," printed", "\n"), return 3 if 1}' print (...) interpreted as function at -e line 1. $ perl -Mstrict -e 'sub foo {print ("This stuff gets"," printed", "\n"), return 3 if 1}' $ -- Peter Scott Pacific Systems Design Technologies
- Re: perl 6 requirements Steve Fink
- Re: perl 6 requirements Randal L. Schwartz
- Re: perl 6 requirements Bart Lateur
- Re: perl 6 requirements Randal L. Schwartz
- Re: perl 6 requirements Graham Barr
- Re: perl 6 requirements Tom Christiansen
- Re: perl 6 requirements Buddha Buck
- Re: perl 6 requirements John Porter
- Re: perl 6 requirements Piers Cawley
- Re: perl 6 requirements Bart Lateur
- Re: perl 6 requirements Peter Scott
- Re: perl 6 requirements Graham Barr
- Re: perl 6 requirements Chaim Frenkel
- Re: perl 6 requirements Randal L. Schwartz
- Re: perl 6 requirements Graham Barr
- Re: perl 6 requirements Randal L. Schwartz
- Re: perl 6 requirements Graham Barr
- Re: perl 6 requirements Randal L. Schwartz
- Re: perl 6 requirements Chaim Frenkel
- Re: perl 6 requirements Alan Burlison
- Re: perl 6 requirements Graham Barr