in reply to rtfm moment...

You know, if you had said...
&dump(-file=>"foo.txt", -code=>"full", -blah=>"etc");

...your script would have worked just fine. Yet another reason to use the unloved ampersand in front of a subroutine call. :)

Hrmm, should perl -w say something when you make a pseudo-ambiguous call to a built-in function? Probably not: that's why I always use the ampersand to disambiguate things.

(Of course, sometimes you *want* function calls to appear a bit ambiguous :)

Replies are listed 'Best First'.
(tye)Re: rtfm moment...
by tye (Sage) on Mar 08, 2001 at 22:22 UTC

    Actually, I think much better advice is to view this as a good reason to always use mixed case in your subroutine names!

    When the "style" shifted from &sub() [Perl4] to just sub() [Perl5], I don't think the documentation and warnings caught up with the problems that resulted. There are probably some warnings that should be added, like you noted, and some advice that needs to be updated and strenthened in the docs.

            - tye (but my friends call me "Tye")