Beginning with v5.6.0, this operator is implemented using the standard "File::Glob" extension. See File::Glob for details, including "bsd_glob" which does not treat whitespace as a pattern separator.
When I look at File::Glob
, I don't see it promising to do "while magic". I see it "returning a list". If the core glob took advantage of this functionality to determine the list it is ready to do "while magic" over, that is a decision made by the core, not (necessarily) a requirement on File::Glob
. Regardless of how File::Glob
might have been "improved" in the v5.6.0 era, it has been behaving in the stated way since then, and it is not
"trivial" to modify that behavior now. That could break existing code, and the porters are notoriously (and justifiably) reluctant to do that.
I agree that emphasizing the absence of "while magic" in the File::Glob documentation could be helpful. I confess to having wondered what was causing the problem with gulliver's code, until I recalled that core glob can do what it does only by "magic". I'm not a big fan of "magic", in part because of problems like this.