diff options
Diffstat (limited to 'perllib/Debian/PkgKde/SymbolsHelper/SymbolFile.pm')
-rw-r--r-- | perllib/Debian/PkgKde/SymbolsHelper/SymbolFile.pm | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/perllib/Debian/PkgKde/SymbolsHelper/SymbolFile.pm b/perllib/Debian/PkgKde/SymbolsHelper/SymbolFile.pm index 081d543..42c7d2b 100644 --- a/perllib/Debian/PkgKde/SymbolsHelper/SymbolFile.pm +++ b/perllib/Debian/PkgKde/SymbolsHelper/SymbolFile.pm @@ -30,11 +30,12 @@ use Debian::PkgKde::SymbolsHelper::Substs; # Use Debian::PkgKde::SymbolsHelper::Symbol as base symbol sub parse { - my ($self, $fh, $file, $seen, $obj_ref, $base_symbol) = @_; - unless (defined $base_symbol) { - $base_symbol = 'Debian::PkgKde::SymbolsHelper::Symbol'; + my ($self, $fh, $file, %opts) = @_; + my $state = $opts{state} //= {}; + unless (defined $state->{base_symbol}) { + $state->{base_symbol} = 'Debian::PkgKde::SymbolsHelper::Symbol'; } - if (!defined $seen) { + unless (defined $state->{seen}) { # Read 'SymbolsHelper-Confirmed' header open(my $fh, "<", $file) or error("unable to open symbol file '$file' for reading"); @@ -46,7 +47,7 @@ sub parse { $self->set_confirmed(split(/\s+/, $1)); } } - return $self->SUPER::parse($fh, $file, $seen, $obj_ref, $base_symbol); + return $self->SUPER::parse($fh, $file, %opts); } sub set_confirmed { |