зеркало из https://github.com/mozilla/gecko-dev.git
Don't try to call the inherited DESTROY destructor, since UNIVERSAL doesn't have one...
This commit is contained in:
Родитель
849440045e
Коммит
a23f79534c
|
@ -465,7 +465,7 @@ sub handle {
|
||||||
|
|
||||||
sub DESTROY {
|
sub DESTROY {
|
||||||
my $self = shift;
|
my $self = shift;
|
||||||
return $self->SUPER::DESTROY(@_) if $self->{'resolved'};
|
return if $self->{'resolved'};
|
||||||
my $parts = 0x00;
|
my $parts = 0x00;
|
||||||
$parts |= 0x01 if scalar(@{$self->{'handlers'}});
|
$parts |= 0x01 if scalar(@{$self->{'handlers'}});
|
||||||
$parts |= 0x02 if defined($self->{'except'});
|
$parts |= 0x02 if defined($self->{'except'});
|
||||||
|
@ -497,7 +497,7 @@ sub create {
|
||||||
|
|
||||||
sub DESTROY {
|
sub DESTROY {
|
||||||
my $self = shift;
|
my $self = shift;
|
||||||
return $self->SUPER::DESTROY(@_) if $self->{'resolved'};
|
return if $self->{'resolved'};
|
||||||
warn "Incorrectly used \"with\" operator at $self->{'filename'} line $self->{'line'}\n"; # XXX can't raise an exception in a destructor
|
warn "Incorrectly used \"with\" operator at $self->{'filename'} line $self->{'line'}\n"; # XXX can't raise an exception in a destructor
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -515,7 +515,7 @@ sub create {
|
||||||
|
|
||||||
sub DESTROY {
|
sub DESTROY {
|
||||||
my $self = shift;
|
my $self = shift;
|
||||||
return $self->SUPER::DESTROY(@_) if $self->{'resolved'};
|
return if $self->{'resolved'};
|
||||||
warn "Incorrectly used \"fallthrough\" function at $self->{'filename'} line $self->{'line'}\n"; # XXX can't raise an exception in a destructor
|
warn "Incorrectly used \"fallthrough\" function at $self->{'filename'} line $self->{'line'}\n"; # XXX can't raise an exception in a destructor
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Загрузка…
Ссылка в новой задаче