| 1 | package Geo::UK::Postcode::Regex::Hash; | ||||||||||||||||||||
| 2 | |||||||||||||||||||||
| 3 | 7 | our $VERSION = '0.015'; | |||||||||||||||||||
| 4 | |||||||||||||||||||||
| 5 | 7 | require Tie::Hash; | |||||||||||||||||||
| 6 | |||||||||||||||||||||
| 7 | 7 | our @ISA = qw/ Tie::StdHash /; | |||||||||||||||||||
| 8 | |||||||||||||||||||||
| 9 | sub TIEHASH { | ||||||||||||||||||||
| 10 | 7 | ▶ | my $class = shift; | ||||||||||||||||||
|
Subroutine
TIEHASH: called CC=1 SCAR=0.0
| |||||||||||||||||||||
| 11 | 7 | return bless {@_}, $class; | |||||||||||||||||||
| 12 | } | ||||||||||||||||||||
| 13 | |||||||||||||||||||||
| 14 | sub FETCH { | ||||||||||||||||||||
| 15 | 34148 | ▶ | my ( $this, $key ) = @_; | ||||||||||||||||||
|
Subroutine
FETCH: called CC=2 SCAR=7.0
| |||||||||||||||||||||
| 16 | 34148 | ▶ | $this->{$key} //= $this->{_fetch}->($key); | ||||||||||||||||||
|
Condition66%2/3
$this->{$key} //= $this->{"_fetch"}->($key)
MC/DC0%0/2
$this->{$key} //= $this->{"_fetch"}->($key)
$this->{$key}
$this->{"_fetch"}->($key)
Truth table66%2/3
A //= B
A= $this->{$key}B= $this->{"_fetch"}->($key)
| |||||||||||||||||||||
| 17 | 34148 | return $this->{$key}; | |||||||||||||||||||
| 18 | } | ||||||||||||||||||||
| 19 | |||||||||||||||||||||
| 20 | 7 | 1; | |||||||||||||||||||
| 21 | |||||||||||||||||||||