my $b1 = join(",", 1..1000);...
my $b2 = join(",", "a".."z");
my @B = glob "{$b1}={$b2}";
my @C;
for (@B){
@C = split /=/;
say "@C";
}
This does not works as I expected because if I change 1000 by 10000
nothing is printed. Somewhere I reach an unexpected limit.
Um, don't do that? The glob function is specifically for filenames
and using it in other ways I suspect is not well supported. I'm going
to guess your "unexpected limit" is the ARG_MAX value in limits.h.
perldoc -f glob says "see File::Glob" and perldoc File::Glob talks
about the various limits.
For your use case, that's fairly simple function to implement in pure
perl.
In comp.lang.perl.misc, gamo <gamo@telecable.es> wrote:
my $b1 = join(",", 1..1000);...
my $b2 = join(",", "a".."z");
my @B = glob "{$b1}={$b2}";
my @C;
for (@B){
@C = split /=/;
say "@C";
}
This does not works as I expected because if I change 1000 by 10000
nothing is printed. Somewhere I reach an unexpected limit.
Um, don't do that? The glob function is specifically for filenames and
using it in other ways I suspect is not well supported. I'm going to
guess your "unexpected limit" is the ARG_MAX value in limits.h.
perldoc -f glob says "see File::Glob" and perldoc File::Glob talks
about the various limits.
For your use case, that's fairly simple function to implement in pure
perl.
In comp.lang.perl.misc, gamo <gamo@telecable.es> wrote:
my $b1 = join(",", 1..1000);...
my $b2 = join(",", "a".."z");
my @B = glob "{$b1}={$b2}";
my @C;
for (@B){
@C = split /=/;
say "@C";
}
This does not works as I expected because if I change 1000 by 10000
nothing is printed. Somewhere I reach an unexpected limit.
Um, don't do that? The glob function is specifically for filenames
and using it in other ways I suspect is not well supported. I'm going
to guess your "unexpected limit" is the ARG_MAX value in limits.h.
perldoc -f glob says "see File::Glob" and perldoc File::Glob talks
about the various limits.
Sysop: | Keyop |
---|---|
Location: | Huddersfield, West Yorkshire, UK |
Users: | 296 |
Nodes: | 16 (2 / 14) |
Uptime: | 61:35:06 |
Calls: | 6,654 |
Files: | 12,200 |
Messages: | 5,331,534 |