On Sat, Sep 21, 2013 at 12:51 PM, Father Chrysostomos via RT <perlbug-followup@perl.org> wrote: > On Sat Sep 21 07:40:33 2013, Hugmeir wrote: I have done a smoke run of smoke-me/hugmeir/dup_glob_state, results available at: <http://www.nntp.perl.org/group/perl.daily-build.reports/2013/09/msg151124.html> I mention that here because unless you have the SHA1s memorized, there is no way from looking at it that you would know what branch was smoked. All the failures there are also happening in blead, i.e., no new test failures. >> On Sat, Sep 21, 2013 at 10:56 AM, Father Chrysostomos via RT < >> perlbug-followup@perl.org> wrote: >> > Your test assumes that the output will be sorted, but does not even use >> > File::Glob on VMS. I don’t know whether the default glob on VMS >> > produces sorted output, and whether you need to sort it. It uses the results of LIB$FIND_FILE, documented at: <http://h71000.www7.hp.com/doc/82final/5932/5932pro_017.html#fin_f> but I see no mention of sorting there. As far as I've ever seen, it's the order the files appear in the directory file, which on any system I've ever worked on means asciibetically. It's possible different locales or local character sets could change the physical order of the directory file, but I don't know that. If it's important I could try to find out. >> >Alternatively, >> > just ‘use File::Glob "glob"’ explicitly, and bypass the globhook >> > mechanism (which VMS ignores) altogether. >> > >> >> Ah, I see, thanks. From the docs, I had assumed that it always gave sorted >> output by default -- perhaps that needs updating to have a clause for VMS >> if that's not the case. I've modified the branch to have a 'use File::Glob >> "glob"'. > > I think perlfunc/glob needs to state that glob is not implemented via > File::Glob on VMS. Does perlfunc/glob really need to say how it's implemented? To me that implies we're not quite sure how it actually works or maybe never decided how it should work. >I don’t know how much of the text there about > whitespace is applicable to VMS’s default glob, so I am not really > qualified to write it. On VMS, glob does not split its arguments on whitespace: $ perl -e "print glob('*.c');" av.cdeb.cdoio.cdoop.cdquote_static.cdump.cgenerate_uudmap.cglobals.cgv.chv.cinline_invlist.ckeywords.clocale.cmadly.cmalloc.cmathoms.cmg.cmg_names.c miniperlmain.cmro.cnumeric.cop.coverload.cpacksizetables.cpad.cperl.cperlapi.cperlio.cperlmain.cPERLMINI.Cperly.cpp.cpp_ctl.cpp_hot.cpp_pack.cpp_sor t.cpp_sys.creentr.cregcomp.cregexec.crun.cscope.csv.ctaint.ctime64.ctoke.cuniversal.cutf8.cutil.cvms.c $ perl -e "print glob('*.c *.h');" $ I don't know when the split on whitespace feature was introduced but it was probably an oversight or lack of tuits that kept it from getting added to the VMS implementation. Whitespace in the pattern is assumed to be part of the filename, and that does work: $ create file^ with_space.txt ^Z $ perl -e "print glob('file with*');" file^_with_space.txt where "^_" is the canonical form of a caret-escaped space character.Thread Previous | Thread Next