At 2:15 AM +0200 2/16/02, Jarkko Hietaniemi wrote:
> > t/op/glob.t
>>
>> The test that is failing is:
>>
>> # ... while ($var = glob(...)) should test definedness not truth
>>
>> my $ok = "not ok 8\n";
>> $ok = "ok 8\n" while my $var = glob("0");
>> print $ok;
>>
>>
>> This test massively confuses me.  What is the meaning of the "0" in
> > C<glob("0")>? 


>Unixism.  If there are no wildcards in the pattern, glob() is supposed
>to return its argument as-is (yes, silly semantics, but I'm innocent).


OK, thanks.  And indeed it does work like that when File::Glob is used:

$ perl -"MFile::Glob" -e "my $a=File::Glob::glob('0'); print $a;"
0

but not when ordinary glob is used:

$ perl -e "my $a=glob('0'); print $a;"
$

and the two are different for us because we have this defined:

$ search configure.com perl_external_glob
$ WC "#define PERL_EXTERNAL_GLOB"

and we have that defined because there are a couple lines in
lib/ExtUtils/MM_VMS.pm that call glob() and this needs to be runnable
from miniperl during the build before File::Glob exists.

I don't suppose there is a way to invoke at run-time the old-style
glob (which for us is really internal, not external)?
-- 
________________________________________
Craig A. Berry
mailto:[EMAIL PROTECTED]

"... getting out of a sonnet is much more
 difficult than getting in."
                 Brad Leithauser

Reply via email to