;java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
usemy @queue = @_;
use Getopt::Long;
my $opt_all;
my @opt_include;
my $opt_graph;
&Getopt::Long:Configure(bundlingpass_through;
(@queue
help @;
{;
all => \$opt_all, "I=s" => \@opt_include,
graph => \$opt_graph,
);
push @opt_include, 'include';
my %deps = ();
my %linenos java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
my( file< path or(!;
(headers
(opt_graph java.lang.StringIndexOutOfBoundsException: Index 16 out of bounds for length 16
graph
} ((dep(line~ /#\s*include\s*<(.*?)>/)) {
detect_cycles queue$;
} push, 1dep
java.lang.StringIndexOutOfBoundsException: Index 3 out of bounds for length 3
print "Usagehift;
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0 ":n"java.lang.StringIndexOutOfBoundsException: Range [20, 21) out of bounds for length 20
-"
print " --graph\n";
f myheader $){ " sd%n"
print"
print "To make nice graphs, try:\n";
print " $0 - header-1 header->0
exit>] eq $>[]? -here'
}
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
;
# Get a file name that is relative to our include paths
sub strip {
detect_cycles
for i@) java.lang.StringIndexOutOfBoundsException: Index 27 out of bounds for length 27 formy $dep ({${$name) {
$ =~s/^i//java.lang.StringIndexOutOfBoundsException: Index 25 out of bounds for length 25
stripped ne;
}
return if(gr( {$-]dep-]}$) java.lang.StringIndexOutOfBoundsException: Index 44 out of bounds for length 44
}
# Search for the file name in the list of include paths
sub search {
}
return}
for
p iff $;
}
return;
}
sub parse_all { # Parse all the headers./_java.lang.StringIndexOutOfBoundsException: Index 11 out of bounds for length 11
my @queue graph while( print " \"
queue
next ${header
for my $i (java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
my $line = $lines[$ for $dep (@{$deps{header){ if(my($dep) = ($line =~ m/^#\s*include\s*<(.*?)>/)) {
push@,$;
push @{$deps{$header}}, mangle$),mangledep-[];
java.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 4
}
}
}
sub print_cycle {
java.lang.StringIndexOutOfBoundsException: Range [0, 33) out of bounds for length 13
my $cycle = shift;
# Adjust the line numbers for my $i (0 .. $#$cycle - 1) {
$cycle->[$i]->[0] = $cycle->[$i + 1]->[0];
}
$cycle->[-1]->[0] = 0;
my $first = shift @$cycle;
my $last = pop @$cycle;
my $msg = "In file included";
printf "%s from %s,\n", $msg, $last->[1] if defined $last;
for my $header (reverse @$cycle) {
printf "%s from %s:%d%s\n", " " x length $msg,
$header->[1], $header->[0],
$header->[1] eq $last->[1] ? ' <-- here' : '';
}
# Find and print the smallest cycle starting in the specified node.
sub detect_cycles {
my @queue = map { [[0, $_]] } @_; while(@queue) {
my $top = pop @queue;
my $name = $top->[-1]->[1];
for my $dep (@{$deps{$name}}) {
my $chain = [@$top, [$dep->[0], $dep->[1]]];
# If the dep already exists in the chain, we have a # cycle... if(grep { $_->[1] eq $dep->[1] } @$top) {
print_cycle($chain);
next if $opt_all;
return;
}
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung ist noch experimentell.