File Coverage

blib/lib/Data/Sah/Compiler/perl/TH/undef.pm
Criterion Covered Total %
statement 18 18 100.0
branch n/a
condition n/a
subroutine 6 6 100.0
pod 0 1 0.0
total 24 25 96.0


line stmt bran cond sub pod time code
1              
2             use 5.010;
3 1     1   29 use strict;
  1         3  
4 1     1   6 use warnings;
  1         2  
  1         19  
5 1     1   5 #use Log::Any '$log';
  1         2  
  1         28  
6              
7             use Mo qw(build default);
8 1     1   6 use Role::Tiny::With;
  1         2  
  1         7  
9 1     1   275  
  1         3  
  1         172  
10             extends 'Data::Sah::Compiler::perl::TH';
11             with 'Data::Sah::Type::undef';
12              
13             our $AUTHORITY = 'cpan:PERLANCAR'; # AUTHORITY
14             our $DATE = '2022-08-20'; # DATE
15             our $DIST = 'Data-Sah'; # DIST
16             our $VERSION = '0.912'; # VERSION
17              
18             my ($self, $cd) = @_;
19             my $c = $self->compiler;
20 6     6 0 14  
21 6         28 my $dt = $cd->{data_term};
22             $cd->{_ccl_check_type} = "!defined($dt)";
23 6         31 }
24 6         18  
25             1;
26             # ABSTRACT: perl's type handler for type "undef"
27              
28              
29             =pod
30              
31             =encoding UTF-8
32              
33             =head1 NAME
34              
35             Data::Sah::Compiler::perl::TH::undef - perl's type handler for type "undef"
36              
37             =head1 VERSION
38              
39             This document describes version 0.912 of Data::Sah::Compiler::perl::TH::undef (from Perl distribution Data-Sah), released on 2022-08-20.
40              
41             =for Pod::Coverage ^(clause_.+|superclause_.+)$
42              
43             =head1 HOMEPAGE
44              
45             Please visit the project's homepage at L<https://metacpan.org/release/Data-Sah>.
46              
47             =head1 SOURCE
48              
49             Source repository is at L<https://github.com/perlancar/perl-Data-Sah>.
50              
51             =head1 AUTHOR
52              
53             perlancar <perlancar@cpan.org>
54              
55             =head1 CONTRIBUTING
56              
57              
58             To contribute, you can send patches by email/via RT, or send pull requests on
59             GitHub.
60              
61             Most of the time, you don't need to build the distribution yourself. You can
62             simply modify the code, then test via:
63              
64             % prove -l
65              
66             If you want to build the distribution (e.g. to try to install it locally on your
67             system), you can install L<Dist::Zilla>,
68             L<Dist::Zilla::PluginBundle::Author::PERLANCAR>,
69             L<Pod::Weaver::PluginBundle::Author::PERLANCAR>, and sometimes one or two other
70             Dist::Zilla- and/or Pod::Weaver plugins. Any additional steps required beyond
71             that are considered a bug and can be reported to me.
72              
73             =head1 COPYRIGHT AND LICENSE
74              
75             This software is copyright (c) 2022, 2021, 2020, 2019, 2018, 2017, 2016, 2015, 2014, 2013, 2012 by perlancar <perlancar@cpan.org>.
76              
77             This is free software; you can redistribute it and/or modify it under
78             the same terms as the Perl 5 programming language system itself.
79              
80             =head1 BUGS
81              
82             Please report any bugs or feature requests on the bugtracker website L<https://rt.cpan.org/Public/Dist/Display.html?Name=Data-Sah>
83              
84             When submitting a bug or request, please include a test-file or a
85             patch to an existing test-file that illustrates the bug or desired
86             feature.
87              
88             =cut