[Date Prev][Date Next][Thread Prev][Thread Next] [Search] [Date Index] [Thread Index]

Re: [FWP] Delayed semantical interpretation



Peter Scott wrote:
> At 01:36 PM 9/23/99 -0400, John Porter wrote:
> >
> >% perl
> >sub foo1($) { print "foo1: @_\n" }
> >sub foo2(&) { print "foo2: @_\n" }
> >
> >foo1 { 'bar', 'quux' };
> >foo2 { 'bar', 'quux' };
> >^D
> >foo1: HASH(0xbc050)
> >foo2: CODE(0xc3bec)
> >
> >I get the exact same results on both 5.004_04 and 5.005_60,
> >with and without -w and strict.
> 
> 
> % perl
> sub foo1($) { print "foo1: @_\n" }
> sub foo2(&) { print "foo2: @_\n" }
> foo1 ( 'bar', 'quux' );
> Too many arguments for main::foo1 at - line 3, near "'quux' )"
> foo2 ( 'bar', 'quux' );
> Type of arg 1 to main::foo2 must be block (not constant item) at - line 4, 
> near "'quux' )"
> Too many arguments for main::foo2 at - line 4, near "'quux' )"

Dude, why didn't you cut-and-paste the code, rather than open yourself
to ridicule?  Try it again.

-- 
John Porter


==== Want to unsubscribe from Fun With Perl?  Well, if you insist...
==== Send email to <fwp-request@technofile.org> with message _body_
====   unsubscribe