| 1 | # Copyrights 2011-2020 by [Mark Overmeer]. | ||
| 2 | # For other contributors see ChangeLog. | ||
| 3 | # See the manual pages for details on the licensing terms. | ||
| 4 | # Pod stripped from pm file by OODoc 2.02. | ||
| 5 | # This code is part of distribution POSIX-1003. Meta-POD processed with | ||
| 6 | # OODoc into POD and HTML manual-pages. See README.md | ||
| 7 | # Copyright Mark Overmeer. Licensed under the same terms as Perl itself. | ||
| 8 | |||
| 9 | package POSIX::1003::Locale; | ||
| 10 | 6 | ▶ | use vars '$VERSION'; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 11 | 6 | $VERSION = '1.02'; | |
| 12 | |||
| 13 | 6 | ▶ | use base 'POSIX::1003::Module'; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 14 | |||
| 15 | 6 | ▶ | use warnings; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 16 | 6 | ▶ | use strict; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 17 | |||
| 18 | # Blocks from resp. limits.h and local.h | ||
| 19 | 6 | my @constants; | |
| 20 | 6 | my @functions = qw/localeconv setlocale/; | |
| 21 | |||
| 22 | 6 | our %EXPORT_TAGS = | |
| 23 | ( constants => \@constants | ||
| 24 | , functions => \@functions | ||
| 25 | , tables => [ '%locale' ] | ||
| 26 | ); | ||
| 27 | |||
| 28 | 6 | my $locale; | |
| 29 | 6 | our %locale; | |
| 30 | |||
| 31 | 6 | ▶ | BEGIN { |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 32 | 6 | $locale = locale_table; | |
| 33 | 6 | push @constants, keys %$locale; | |
| 34 | 6 | tie %locale, 'POSIX::1003::ReadOnlyTable', $locale; | |
| 35 | } | ||
| 36 | |||
| 37 | |||
| 38 | sub _create_constant($) | ||
| 39 | 19 | ▶ | { my ($class, $name) = @_; |
|
Subroutine
_create_constant: called CC=1 SCAR=0.2
| |||
| 40 | 19 | my $val = $locale->{$name}; | |
| 41 | 0 | ▶ | sub () {$val}; |
|
Subroutine
__ANON__: not called CC=1 SCAR=1.2
| |||
| 42 | } | ||
| 43 | |||
| 44 | |||
| 45 | 6 | 1; | |