develooper Front page | perl.perl5.porters | Postings from April 2000

Re: [ID 20000410.003] File::Glob qw(:glob) does not work

Thread Previous | Thread Next
Gurusamy Sarathy
April 10, 2000 08:47
Re: [ID 20000410.003] File::Glob qw(:glob) does not work
Message ID:
On Mon, 10 Apr 2000 08:45:14 +0200, Marc Lehmann wrote:
>File::Glob does not properly export it's glob function:
>cerebro:~# perl -e 'use File::Glob ":glob"; glob "/tmp/*", GLOB_NOSORT'
>Too many arguments for glob at -e line 1, at EOF
>Execution of -e aborted due to compilation errors.
>[Exit 255] 
>However, qualifying glob with the package name works:
>cerebro:~# perl -e 'use File::Glob ":glob"; File::Glob::glob "/tmp/*", GLOB_NOSORT'
>Looks like a prototype error.

I'd say it was a mistake to have named File::Glob::glob() the same name
as a builtin, when it doesn't have the same prototype as that builtin.

We should probably rename it and deprecate File::Glob::glob().  Patch


Thread Previous | Thread Next Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About