Filename | /Users/timbo/perl5/perlbrew/perls/perl-5.18.2/lib/site_perl/5.18.2/Path/IsDev.pm |
Statements | Executed 19 statements in 427µs |
Calls | P | F | Exclusive Time |
Inclusive Time |
Subroutine |
---|---|---|---|---|---|
1 | 1 | 1 | 1.92ms | 4.39ms | BEGIN@261 | Path::IsDev::
1 | 1 | 1 | 14µs | 14µs | BEGIN@1 | File::ShareDir::ProjectDistDir::
1 | 1 | 1 | 7µs | 10µs | BEGIN@3 | File::ShareDir::ProjectDistDir::
1 | 1 | 1 | 7µs | 8µs | BEGIN@4 | File::ShareDir::ProjectDistDir::
1 | 1 | 1 | 6µs | 17µs | BEGIN@2 | File::ShareDir::ProjectDistDir::
1 | 1 | 1 | 4µs | 4µs | _build_is_dev | Path::IsDev::
0 | 0 | 0 | 0s | 0s | __ANON__[:293] | Path::IsDev::
0 | 0 | 0 | 0s | 0s | debug | Path::IsDev::
Line | State ments |
Time on line |
Calls | Time in subs |
Code |
---|---|---|---|---|---|
1 | 2 | 35µs | 1 | 14µs | # spent 14µs within File::ShareDir::ProjectDistDir::BEGIN@1 which was called:
# once (14µs+0s) by File::ShareDir::ProjectDistDir::BEGIN@234 at line 1 # spent 14µs making 1 call to File::ShareDir::ProjectDistDir::BEGIN@1 |
2 | 2 | 18µs | 2 | 28µs | # spent 17µs (6+11) within File::ShareDir::ProjectDistDir::BEGIN@2 which was called:
# once (6µs+11µs) by File::ShareDir::ProjectDistDir::BEGIN@234 at line 2 # spent 17µs making 1 call to File::ShareDir::ProjectDistDir::BEGIN@2
# spent 11µs making 1 call to strict::import |
3 | 2 | 18µs | 2 | 14µs | # spent 10µs (7+4) within File::ShareDir::ProjectDistDir::BEGIN@3 which was called:
# once (7µs+4µs) by File::ShareDir::ProjectDistDir::BEGIN@234 at line 3 # spent 10µs making 1 call to File::ShareDir::ProjectDistDir::BEGIN@3
# spent 4µs making 1 call to warnings::import |
4 | 2 | 100µs | 2 | 9µs | # spent 8µs (7+1) within File::ShareDir::ProjectDistDir::BEGIN@4 which was called:
# once (7µs+1µs) by File::ShareDir::ProjectDistDir::BEGIN@234 at line 4 # spent 8µs making 1 call to File::ShareDir::ProjectDistDir::BEGIN@4
# spent 1µs making 1 call to utf8::import |
5 | |||||
6 | package Path::IsDev; | ||||
7 | 1 | 600ns | $Path::IsDev::VERSION = '1.001000'; | ||
8 | # ABSTRACT: Determine if a given Path resembles a development source tree | ||||
9 | |||||
10 | 1 | 200ns | our $AUTHORITY = 'cpan:KENTNL'; # AUTHORITY | ||
11 | |||||
- - | |||||
261 | 2 | 240µs | 2 | 4.65ms | # spent 4.39ms (1.92+2.47) within Path::IsDev::BEGIN@261 which was called:
# once (1.92ms+2.47ms) by File::ShareDir::ProjectDistDir::BEGIN@234 at line 261 # spent 4.39ms making 1 call to Path::IsDev::BEGIN@261
# spent 262µs making 1 call to Sub::Exporter::__ANON__[Sub/Exporter.pm:337] |
262 | |||||
263 | 1 | 200ns | our $ENV_KEY_DEBUG = 'PATH_ISDEV_DEBUG'; | ||
264 | |||||
265 | 1 | 800ns | our $DEBUG = ( exists $ENV{$ENV_KEY_DEBUG} ? $ENV{$ENV_KEY_DEBUG} : undef ); | ||
266 | |||||
- - | |||||
277 | sub debug { | ||||
278 | return unless $DEBUG; | ||||
279 | return *STDERR->printf( qq{[Path::IsDev] %s\n}, shift ); | ||||
280 | } | ||||
281 | |||||
282 | # spent 4µs within Path::IsDev::_build_is_dev which was called:
# once (4µs+0s) by File::ShareDir::ProjectDistDir::BEGIN@234 at line 319 | ||||
283 | 1 | 500ns | my ( undef, undef, $arg ) = @_; | ||
284 | |||||
285 | 1 | 100ns | my $isdev_object; | ||
286 | return sub { | ||||
287 | my ($path) = @_; | ||||
288 | $isdev_object ||= do { | ||||
289 | require Path::IsDev::Object; | ||||
290 | Path::IsDev::Object->new( %{ $arg || {} } ); | ||||
291 | }; | ||||
292 | return $isdev_object->matches($path); | ||||
293 | 1 | 7µs | }; | ||
294 | } | ||||
295 | |||||
- - | |||||
319 | 1 | 3µs | 1 | 4µs | *is_dev = _build_is_dev( 'Path::IsDev', 'is_dev', {} ); # spent 4µs making 1 call to Path::IsDev::_build_is_dev |
320 | |||||
321 | 1 | 4µs | 1; | ||
322 | |||||
323 | __END__ |