29.01.2015, 13:51, "James E Keenan via RT" <perlbug-followup@perl.org>: > On Wed Jan 28 10:39:13 2015, porton@narod.ru wrote: >> This is a bug report for perl from porton@narod.ru, >> generated with the help of perlbug 1.40 running under perl 5.20.1. >> >> ----------------------------------------------------------------- >> I suggest to add to Perl core a routine similar to glob(), but >> using regexps instead of globs. > > But that functionality already exists, does it not? > > (untested) > ##### > opendir my $DIR, 'some/directory' or die; > my @files = grep { m/some_pattern/ } readdir $DIR; > closedir or die; > ##### It is better to do it in one line rather than three ones. -- Victor Porton - http://portonvictor.orgThread Previous | Thread Next