in reply to how to create pod.idx
Couldn't find the FM either. Here's the code...I guess this is RTFC ;) It's in Pod::Perldoc. Command line option -X translates to the attribute podidx in the Pod::Perldoc::options_processing method. Pod::Perldoc::grand_search_init is where packages are found matching the search package.
sub grand_search_init { my($self, $pages, @found) = @_; foreach (@$pages) { if ($self->{'podidx'} && open(PODIDX, $self->{'podidx'})) { my $searchfor = catfile split '::', $_; $self->aside( "Searching for '$searchfor' in $self->{'podi +dx'}\n" ); local $_; while (<PODIDX>) { chomp; push(@found, $_) if m,/$searchfor(?:\.(?:pod|pm))?\z,i +; } close(PODIDX) or die "Can't close $$self{'podid +x'}: $!"; next; } ...
It looks like the .idx file would speed up searches for package pod if the .idx file existed.
Hope that helps.
|
|---|