line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
#! /bin/false |
2
|
|
|
|
|
|
|
|
3
|
|
|
|
|
|
|
# vim: set autoindent shiftwidth=4 tabstop=4: |
4
|
|
|
|
|
|
|
|
5
|
|
|
|
|
|
|
# Copyright (C) 2002-2017 Guido Flohr , |
6
|
|
|
|
|
|
|
# all rights reserved. |
7
|
|
|
|
|
|
|
|
8
|
|
|
|
|
|
|
# This program is free software: you can redistribute it and/or modify |
9
|
|
|
|
|
|
|
# it under the terms of the GNU General Public License as published by |
10
|
|
|
|
|
|
|
# the Free Software Foundation; either version 3 of the License, or |
11
|
|
|
|
|
|
|
# (at your option) any later version. |
12
|
|
|
|
|
|
|
|
13
|
|
|
|
|
|
|
# This program is distributed in the hope that it will be useful, |
14
|
|
|
|
|
|
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of |
15
|
|
|
|
|
|
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
16
|
|
|
|
|
|
|
# GNU General Public License for more details. |
17
|
|
|
|
|
|
|
|
18
|
|
|
|
|
|
|
# You should have received a copy of the GNU General Public License |
19
|
|
|
|
|
|
|
# along with this program. If not, see . |
20
|
|
|
|
|
|
|
|
21
|
|
|
|
|
|
|
package Locale::Messages; |
22
|
|
|
|
|
|
|
|
23
|
25
|
|
|
25
|
|
107104
|
use strict; |
|
25
|
|
|
|
|
213
|
|
|
25
|
|
|
|
|
2980
|
|
24
|
|
|
|
|
|
|
|
25
|
25
|
|
|
25
|
|
131
|
use vars qw ($package @EXPORT_OK %EXPORT_TAGS @ISA $VERSION); |
|
25
|
|
|
|
|
47
|
|
|
25
|
|
|
|
|
9005
|
|
26
|
|
|
|
|
|
|
|
27
|
|
|
|
|
|
|
$VERSION = '1.33'; |
28
|
|
|
|
|
|
|
|
29
|
|
|
|
|
|
|
# Try to load the C version first. |
30
|
|
|
|
|
|
|
$package = 'gettext_xs'; |
31
|
|
|
|
|
|
|
|
32
|
|
|
|
|
|
|
# Do not load from current working directory. |
33
|
|
|
|
|
|
|
local @INC = grep { $_ ne '.' } @INC; |
34
|
|
|
|
|
|
|
|
35
|
|
|
|
|
|
|
eval <<'EOF'; |
36
|
|
|
|
|
|
|
require Locale::gettext_xs; |
37
|
|
|
|
|
|
|
my $version = Locale::gettext_xs::__gettext_xs_version(); |
38
|
|
|
|
|
|
|
die "Version: version mismatch ($VERSION vs. $version)" unless $version eq $VERSION; |
39
|
|
|
|
|
|
|
EOF |
40
|
|
|
|
|
|
|
my $no_xs = $@; |
41
|
|
|
|
|
|
|
|
42
|
|
|
|
|
|
|
# There are systems where setlocale() and the LC_ constants are not |
43
|
|
|
|
|
|
|
# defined at all, see https://rt.cpan.org/Ticket/Display.html?id=98109 |
44
|
|
|
|
|
|
|
# |
45
|
|
|
|
|
|
|
# On such systems, we always fall back to gettext_dumb. |
46
|
|
|
|
|
|
|
if ($no_xs) { |
47
|
|
|
|
|
|
|
eval { |
48
|
|
|
|
|
|
|
require POSIX; |
49
|
|
|
|
|
|
|
# void |
50
|
|
|
|
|
|
|
POSIX::setlocale(POSIX::LC_ALL()); |
51
|
|
|
|
|
|
|
}; |
52
|
|
|
|
|
|
|
if ($@) { |
53
|
|
|
|
|
|
|
$package = 'gettext_dumb'; |
54
|
|
|
|
|
|
|
require Locale::gettext_dumb; |
55
|
|
|
|
|
|
|
} else { |
56
|
|
|
|
|
|
|
$package = 'gettext_pp'; |
57
|
|
|
|
|
|
|
require Locale::gettext_pp; |
58
|
|
|
|
|
|
|
} |
59
|
|
|
|
|
|
|
} |
60
|
|
|
|
|
|
|
|
61
|
|
|
|
|
|
|
require Exporter; |
62
|
|
|
|
|
|
|
@ISA = qw (Exporter); |
63
|
|
|
|
|
|
|
%EXPORT_TAGS = (locale_h => [ qw (gettext |
64
|
|
|
|
|
|
|
dgettext |
65
|
|
|
|
|
|
|
dcgettext |
66
|
|
|
|
|
|
|
ngettext |
67
|
|
|
|
|
|
|
dngettext |
68
|
|
|
|
|
|
|
dcngettext |
69
|
|
|
|
|
|
|
pgettext |
70
|
|
|
|
|
|
|
dpgettext |
71
|
|
|
|
|
|
|
dcpgettext |
72
|
|
|
|
|
|
|
npgettext |
73
|
|
|
|
|
|
|
dnpgettext |
74
|
|
|
|
|
|
|
dcnpgettext |
75
|
|
|
|
|
|
|
textdomain |
76
|
|
|
|
|
|
|
bindtextdomain |
77
|
|
|
|
|
|
|
bind_textdomain_codeset |
78
|
|
|
|
|
|
|
) |
79
|
|
|
|
|
|
|
], |
80
|
|
|
|
|
|
|
libintl_h => [ qw (LC_CTYPE |
81
|
|
|
|
|
|
|
LC_NUMERIC |
82
|
|
|
|
|
|
|
LC_TIME |
83
|
|
|
|
|
|
|
LC_COLLATE |
84
|
|
|
|
|
|
|
LC_MONETARY |
85
|
|
|
|
|
|
|
LC_MESSAGES |
86
|
|
|
|
|
|
|
LC_ALL) |
87
|
|
|
|
|
|
|
], |
88
|
|
|
|
|
|
|
); |
89
|
|
|
|
|
|
|
|
90
|
|
|
|
|
|
|
@EXPORT_OK = qw (select_package |
91
|
|
|
|
|
|
|
turn_utf_8_on |
92
|
|
|
|
|
|
|
turn_utf_8_off |
93
|
|
|
|
|
|
|
gettext |
94
|
|
|
|
|
|
|
dgettext |
95
|
|
|
|
|
|
|
dcgettext |
96
|
|
|
|
|
|
|
ngettext |
97
|
|
|
|
|
|
|
dngettext |
98
|
|
|
|
|
|
|
dcngettext |
99
|
|
|
|
|
|
|
pgettext |
100
|
|
|
|
|
|
|
dpgettext |
101
|
|
|
|
|
|
|
dcpgettext |
102
|
|
|
|
|
|
|
npgettext |
103
|
|
|
|
|
|
|
dnpgettext |
104
|
|
|
|
|
|
|
dcnpgettext |
105
|
|
|
|
|
|
|
textdomain |
106
|
|
|
|
|
|
|
bindtextdomain |
107
|
|
|
|
|
|
|
bind_textdomain_codeset |
108
|
|
|
|
|
|
|
bind_textdomain_filter |
109
|
|
|
|
|
|
|
nl_putenv |
110
|
|
|
|
|
|
|
setlocale |
111
|
|
|
|
|
|
|
LC_CTYPE |
112
|
|
|
|
|
|
|
LC_NUMERIC |
113
|
|
|
|
|
|
|
LC_TIME |
114
|
|
|
|
|
|
|
LC_COLLATE |
115
|
|
|
|
|
|
|
LC_MONETARY |
116
|
|
|
|
|
|
|
LC_MESSAGES |
117
|
|
|
|
|
|
|
LC_ALL); |
118
|
|
|
|
|
|
|
|
119
|
|
|
|
|
|
|
BEGIN { |
120
|
25
|
|
|
25
|
|
102
|
my ($has_encode, $has_bytes); |
121
|
|
|
|
|
|
|
|
122
|
25
|
50
|
|
|
|
118
|
if ($] >= 5.006) { |
123
|
25
|
50
|
|
|
|
1862
|
unless (defined $has_encode) { |
124
|
25
|
|
|
|
|
1512
|
eval "require Encode"; |
125
|
25
|
|
|
|
|
284036
|
$has_encode = !$@; |
126
|
|
|
|
|
|
|
} |
127
|
|
|
|
|
|
|
|
128
|
25
|
50
|
33
|
|
|
114
|
unless ($has_encode || defined $has_bytes) { |
129
|
0
|
|
|
|
|
0
|
eval "use bytes"; |
130
|
0
|
|
|
|
|
0
|
$has_bytes = !$@; |
131
|
|
|
|
|
|
|
} |
132
|
|
|
|
|
|
|
} |
133
|
|
|
|
|
|
|
|
134
|
|
|
|
|
|
|
# Turn the UTF-8 flag on or off unconditionally. The prototypes |
135
|
|
|
|
|
|
|
# allow an optional second parameter, so that you can use the |
136
|
|
|
|
|
|
|
# functions as callbacks to bind_textdomain_filter. |
137
|
25
|
50
|
|
|
|
88
|
if ($has_encode) { |
|
|
0
|
|
|
|
|
|
138
|
25
|
|
|
1607
|
1
|
8280
|
eval <<'EOF'; |
|
1607
|
|
|
0
|
1
|
5369
|
|
|
1607
|
|
|
|
|
3588
|
|
|
0
|
|
|
|
|
0
|
|
|
0
|
|
|
|
|
0
|
|
139
|
|
|
|
|
|
|
sub turn_utf_8_on($;$) |
140
|
|
|
|
|
|
|
{ |
141
|
|
|
|
|
|
|
Encode::_utf8_on ($_[0]); |
142
|
|
|
|
|
|
|
return $_[0]; |
143
|
|
|
|
|
|
|
} |
144
|
|
|
|
|
|
|
|
145
|
|
|
|
|
|
|
sub turn_utf_8_off($;$) |
146
|
|
|
|
|
|
|
{ |
147
|
|
|
|
|
|
|
Encode::_utf8_off ($_[0]); |
148
|
|
|
|
|
|
|
return $_[0]; |
149
|
|
|
|
|
|
|
} |
150
|
|
|
|
|
|
|
|
151
|
|
|
|
|
|
|
EOF |
152
|
|
|
|
|
|
|
} elsif ($has_bytes) { |
153
|
0
|
|
|
|
|
0
|
eval <<'EOF'; |
154
|
|
|
|
|
|
|
sub turn_utf_8_on($;$) |
155
|
|
|
|
|
|
|
{ |
156
|
|
|
|
|
|
|
$_[0] = pack "U0C*", unpack "C*", $_[0]; |
157
|
|
|
|
|
|
|
} |
158
|
|
|
|
|
|
|
|
159
|
|
|
|
|
|
|
sub turn_utf_8_off($;$) |
160
|
|
|
|
|
|
|
{ |
161
|
|
|
|
|
|
|
use bytes; |
162
|
|
|
|
|
|
|
$_[0] = join "", split //, $_[0]; |
163
|
|
|
|
|
|
|
} |
164
|
|
|
|
|
|
|
|
165
|
|
|
|
|
|
|
EOF |
166
|
|
|
|
|
|
|
} else { |
167
|
0
|
|
|
|
|
0
|
eval <<'EOF'; |
168
|
|
|
|
|
|
|
sub turn_utf_8_on($;$) |
169
|
|
|
|
|
|
|
{ |
170
|
|
|
|
|
|
|
return $_[0]; |
171
|
|
|
|
|
|
|
} |
172
|
|
|
|
|
|
|
|
173
|
|
|
|
|
|
|
sub turn_utf_8_off($;$) |
174
|
|
|
|
|
|
|
{ |
175
|
|
|
|
|
|
|
return $_[0]; |
176
|
|
|
|
|
|
|
} |
177
|
|
|
|
|
|
|
|
178
|
|
|
|
|
|
|
EOF |
179
|
|
|
|
|
|
|
} |
180
|
|
|
|
|
|
|
} |
181
|
|
|
|
|
|
|
|
182
|
|
|
|
|
|
|
# The textdomain could be undef. We avoid a warning by specifying |
183
|
|
|
|
|
|
|
# a filter for the undefined textdomain. |
184
|
|
|
|
|
|
|
my %filters = (undef => \&turn_utf_8_off); |
185
|
|
|
|
|
|
|
|
186
|
|
|
|
|
|
|
sub select_package { |
187
|
21
|
|
|
21
|
1
|
6586
|
my ($pkg, $compatibility) = @_; |
188
|
|
|
|
|
|
|
|
189
|
|
|
|
|
|
|
# Compatibility quirk for a bug pre 1.17: |
190
|
21
|
50
|
33
|
|
|
153
|
if (__PACKAGE__ eq $pkg && defined $compatibility) { |
191
|
21
|
|
|
|
|
40
|
$pkg = $compatibility; |
192
|
|
|
|
|
|
|
} |
193
|
|
|
|
|
|
|
|
194
|
21
|
50
|
33
|
|
|
170
|
if ($no_xs && 'gettext_xs' eq $pkg) { |
195
|
0
|
|
|
|
|
0
|
$pkg = 'gettext_pp'; |
196
|
|
|
|
|
|
|
} |
197
|
|
|
|
|
|
|
|
198
|
21
|
100
|
66
|
|
|
260
|
if (defined $pkg && 'gettext_pp' eq $pkg) { |
|
|
50
|
|
|
|
|
|
199
|
|
|
|
|
|
|
# This branch is not unnecessary. The next (elsif) branch does |
200
|
|
|
|
|
|
|
# essentially the same but catches compilation errors. |
201
|
20
|
|
|
|
|
9711
|
require Locale::gettext_pp; |
202
|
20
|
|
|
|
|
85
|
$package = 'gettext_pp'; |
203
|
|
|
|
|
|
|
} elsif (defined $pkg) { |
204
|
1
|
|
|
|
|
4
|
my $filename = "Locale::$pkg"; |
205
|
1
|
|
|
|
|
11
|
$filename =~ s{::|\'}{/}; |
206
|
1
|
|
|
|
|
3
|
$filename .= '.pm'; |
207
|
1
|
|
|
|
|
38
|
eval { require $filename }; |
|
1
|
|
|
|
|
525
|
|
208
|
1
|
50
|
|
|
|
7
|
$package = $pkg unless $@; |
209
|
|
|
|
|
|
|
} else { |
210
|
0
|
|
|
|
|
0
|
eval "require Locale::gettext_xs"; |
211
|
0
|
0
|
|
|
|
0
|
$package = 'gettext_xs' unless $@; |
212
|
|
|
|
|
|
|
} |
213
|
|
|
|
|
|
|
|
214
|
21
|
|
|
|
|
160
|
return $package; |
215
|
|
|
|
|
|
|
} |
216
|
|
|
|
|
|
|
|
217
|
|
|
|
|
|
|
sub bind_textdomain_filter ($;$$) { |
218
|
1
|
|
|
1
|
1
|
16
|
my ($textdomain, $coderef, $data) = @_; |
219
|
|
|
|
|
|
|
|
220
|
1
|
|
|
|
|
3
|
$filters{$textdomain} = [ $coderef, $data ]; |
221
|
|
|
|
|
|
|
|
222
|
1
|
|
|
|
|
7
|
return 1; |
223
|
|
|
|
|
|
|
} |
224
|
|
|
|
|
|
|
|
225
|
|
|
|
|
|
|
sub textdomain (;$) { |
226
|
209
|
|
|
209
|
1
|
5649
|
my $function = "Locale::${package}::textdomain"; |
227
|
|
|
|
|
|
|
|
228
|
25
|
|
|
25
|
|
211
|
no strict 'refs'; |
|
25
|
|
|
|
|
61
|
|
|
25
|
|
|
|
|
1905
|
|
229
|
209
|
|
|
|
|
667
|
&$function; |
230
|
|
|
|
|
|
|
} |
231
|
|
|
|
|
|
|
|
232
|
|
|
|
|
|
|
sub bindtextdomain ($;$) { |
233
|
41
|
|
|
41
|
1
|
6312
|
my $function = "Locale::${package}::bindtextdomain"; |
234
|
|
|
|
|
|
|
|
235
|
25
|
|
|
25
|
|
190
|
no strict 'refs'; |
|
25
|
|
|
|
|
53
|
|
|
25
|
|
|
|
|
1920
|
|
236
|
41
|
|
|
|
|
181
|
&$function; |
237
|
|
|
|
|
|
|
} |
238
|
|
|
|
|
|
|
|
239
|
|
|
|
|
|
|
sub bind_textdomain_codeset ($;$) { |
240
|
2
|
|
|
2
|
1
|
1298
|
my $function = "Locale::${package}::bind_textdomain_codeset"; |
241
|
|
|
|
|
|
|
|
242
|
25
|
|
|
25
|
|
161
|
no strict 'refs'; |
|
25
|
|
|
|
|
62
|
|
|
25
|
|
|
|
|
2534
|
|
243
|
2
|
|
|
|
|
8
|
&$function; |
244
|
|
|
|
|
|
|
} |
245
|
|
|
|
|
|
|
|
246
|
|
|
|
|
|
|
sub gettext ($) { |
247
|
106
|
|
|
106
|
1
|
1764
|
my $textdomain = textdomain; |
248
|
106
|
|
100
|
|
|
382
|
$filters{$textdomain} ||= [ \&turn_utf_8_off ]; |
249
|
106
|
|
|
|
|
167
|
my $cb = $filters{$textdomain}; |
250
|
|
|
|
|
|
|
|
251
|
106
|
|
|
|
|
197
|
my $function = "Locale::${package}::gettext"; |
252
|
|
|
|
|
|
|
|
253
|
25
|
|
|
25
|
|
192
|
no strict 'refs'; |
|
25
|
|
|
|
|
48
|
|
|
25
|
|
|
|
|
3118
|
|
254
|
106
|
|
|
|
|
290
|
$cb->[0] (&$function, $cb->[1]); |
255
|
|
|
|
|
|
|
} |
256
|
|
|
|
|
|
|
|
257
|
|
|
|
|
|
|
sub dgettext($$) { |
258
|
12
|
|
100
|
12
|
1
|
1217
|
my $cb = $filters{$_[0]} ||= [ \&turn_utf_8_off ]; |
259
|
|
|
|
|
|
|
|
260
|
12
|
|
|
|
|
38
|
my $function = "Locale::${package}::dgettext"; |
261
|
|
|
|
|
|
|
|
262
|
25
|
|
|
25
|
|
175
|
no strict 'refs'; |
|
25
|
|
|
|
|
44
|
|
|
25
|
|
|
|
|
2970
|
|
263
|
12
|
|
|
|
|
49
|
$cb->[0] (&$function, $cb->[1]); |
264
|
|
|
|
|
|
|
} |
265
|
|
|
|
|
|
|
|
266
|
|
|
|
|
|
|
sub dcgettext($$$) { |
267
|
12
|
|
100
|
12
|
1
|
57
|
my $cb = $filters{$_[0]} ||= [ \&turn_utf_8_off ]; |
268
|
|
|
|
|
|
|
|
269
|
12
|
|
|
|
|
29
|
my $function = "Locale::${package}::dcgettext"; |
270
|
|
|
|
|
|
|
|
271
|
25
|
|
|
25
|
|
217
|
no strict 'refs'; |
|
25
|
|
|
|
|
82
|
|
|
25
|
|
|
|
|
3193
|
|
272
|
12
|
|
|
|
|
42
|
$cb->[0] (&$function, $cb->[1]); |
273
|
|
|
|
|
|
|
} |
274
|
|
|
|
|
|
|
|
275
|
|
|
|
|
|
|
sub ngettext($$$) { |
276
|
83
|
|
|
83
|
1
|
4262
|
my $textdomain = textdomain; |
277
|
83
|
|
100
|
|
|
214
|
$filters{$textdomain} ||= [ \&turn_utf_8_off ]; |
278
|
83
|
|
|
|
|
120
|
my $cb = $filters{$textdomain}; |
279
|
|
|
|
|
|
|
|
280
|
83
|
|
|
|
|
148
|
my $function = "Locale::${package}::ngettext"; |
281
|
|
|
|
|
|
|
|
282
|
25
|
|
|
25
|
|
171
|
no strict 'refs'; |
|
25
|
|
|
|
|
62
|
|
|
25
|
|
|
|
|
3143
|
|
283
|
83
|
|
|
|
|
232
|
$cb->[0] (&$function, $cb->[1]); |
284
|
|
|
|
|
|
|
} |
285
|
|
|
|
|
|
|
|
286
|
|
|
|
|
|
|
sub dngettext($$$$) { |
287
|
83
|
|
100
|
83
|
1
|
22456
|
my $cb = $filters{$_[0]} ||= [ \&turn_utf_8_off ]; |
288
|
|
|
|
|
|
|
|
289
|
83
|
|
|
|
|
209
|
my $function = "Locale::${package}::dngettext"; |
290
|
|
|
|
|
|
|
|
291
|
25
|
|
|
25
|
|
178
|
no strict 'refs'; |
|
25
|
|
|
|
|
46
|
|
|
25
|
|
|
|
|
2767
|
|
292
|
83
|
|
|
|
|
320
|
$cb->[0] (&$function, $cb->[1]); |
293
|
|
|
|
|
|
|
} |
294
|
|
|
|
|
|
|
|
295
|
|
|
|
|
|
|
sub dcngettext($$$$$) { |
296
|
83
|
|
100
|
83
|
1
|
228
|
my $cb = $filters{$_[0]} ||= [ \&turn_utf_8_off ]; |
297
|
|
|
|
|
|
|
|
298
|
83
|
|
|
|
|
134
|
my $function = "Locale::${package}::dcngettext"; |
299
|
|
|
|
|
|
|
|
300
|
25
|
|
|
25
|
|
166
|
no strict 'refs'; |
|
25
|
|
|
|
|
49
|
|
|
25
|
|
|
|
|
2981
|
|
301
|
83
|
|
|
|
|
235
|
$cb->[0] (&$function, $cb->[1]); |
302
|
|
|
|
|
|
|
} |
303
|
|
|
|
|
|
|
|
304
|
|
|
|
|
|
|
sub pgettext($$) { |
305
|
3
|
|
|
3
|
1
|
18
|
my $textdomain = textdomain; |
306
|
3
|
|
50
|
|
|
34
|
$filters{$textdomain} ||= [ \&turn_utf_8_off ]; |
307
|
3
|
|
|
|
|
8
|
my $cb = $filters{$textdomain}; |
308
|
|
|
|
|
|
|
|
309
|
3
|
|
|
|
|
8
|
my $function = "Locale::${package}::pgettext"; |
310
|
|
|
|
|
|
|
|
311
|
25
|
|
|
25
|
|
166
|
no strict 'refs'; |
|
25
|
|
|
|
|
68
|
|
|
25
|
|
|
|
|
2943
|
|
312
|
3
|
|
|
|
|
10
|
$cb->[0] (&$function, $cb->[1]); |
313
|
|
|
|
|
|
|
} |
314
|
|
|
|
|
|
|
|
315
|
|
|
|
|
|
|
sub dpgettext($$$) { |
316
|
4
|
|
100
|
4
|
1
|
21
|
my $cb = $filters{$_[0]} ||= [ \&turn_utf_8_off ]; |
317
|
|
|
|
|
|
|
|
318
|
4
|
|
|
|
|
11
|
my $function = "Locale::${package}::dpgettext"; |
319
|
|
|
|
|
|
|
|
320
|
25
|
|
|
25
|
|
184
|
no strict 'refs'; |
|
25
|
|
|
|
|
60
|
|
|
25
|
|
|
|
|
2814
|
|
321
|
4
|
|
|
|
|
18
|
$cb->[0] (&$function, $cb->[1]); |
322
|
|
|
|
|
|
|
} |
323
|
|
|
|
|
|
|
|
324
|
|
|
|
|
|
|
sub dcpgettext($$$$) { |
325
|
5
|
|
100
|
5
|
1
|
23
|
my $cb = $filters{$_[0]} ||= [ \&turn_utf_8_off ]; |
326
|
|
|
|
|
|
|
|
327
|
5
|
|
|
|
|
11
|
my $function = "Locale::${package}::dcpgettext"; |
328
|
|
|
|
|
|
|
|
329
|
25
|
|
|
25
|
|
186
|
no strict 'refs'; |
|
25
|
|
|
|
|
66
|
|
|
25
|
|
|
|
|
2668
|
|
330
|
5
|
|
|
|
|
24
|
$cb->[0] (&$function, $cb->[1]); |
331
|
|
|
|
|
|
|
} |
332
|
|
|
|
|
|
|
|
333
|
|
|
|
|
|
|
sub npgettext($$$$) { |
334
|
91
|
|
100
|
91
|
1
|
4777
|
my $cb = $filters{$_[0]} ||= [ \&turn_utf_8_off ]; |
335
|
|
|
|
|
|
|
|
336
|
91
|
|
|
|
|
204
|
my $function = "Locale::${package}::npgettext"; |
337
|
|
|
|
|
|
|
|
338
|
25
|
|
|
25
|
|
164
|
no strict 'refs'; |
|
25
|
|
|
|
|
67
|
|
|
25
|
|
|
|
|
2734
|
|
339
|
91
|
|
|
|
|
299
|
$cb->[0] (&$function, $cb->[1]); |
340
|
|
|
|
|
|
|
} |
341
|
|
|
|
|
|
|
|
342
|
|
|
|
|
|
|
sub dnpgettext($$$$$) { |
343
|
91
|
|
100
|
91
|
1
|
4533
|
my $cb = $filters{$_[0]} ||= [ \&turn_utf_8_off ]; |
344
|
|
|
|
|
|
|
|
345
|
91
|
|
|
|
|
202
|
my $function = "Locale::${package}::dnpgettext"; |
346
|
|
|
|
|
|
|
|
347
|
25
|
|
|
25
|
|
199
|
no strict 'refs'; |
|
25
|
|
|
|
|
53
|
|
|
25
|
|
|
|
|
2661
|
|
348
|
91
|
|
|
|
|
315
|
$cb->[0] (&$function, $cb->[1]); |
349
|
|
|
|
|
|
|
} |
350
|
|
|
|
|
|
|
|
351
|
|
|
|
|
|
|
sub dcnpgettext($$$$$$) { |
352
|
91
|
|
100
|
91
|
1
|
310
|
my $cb = $filters{$_[0]} ||= [ \&turn_utf_8_off ]; |
353
|
|
|
|
|
|
|
|
354
|
91
|
|
|
|
|
181
|
my $function = "Locale::${package}::dcnpgettext"; |
355
|
|
|
|
|
|
|
|
356
|
25
|
|
|
25
|
|
171
|
no strict 'refs'; |
|
25
|
|
|
|
|
66
|
|
|
25
|
|
|
|
|
2319
|
|
357
|
91
|
|
|
|
|
255
|
$cb->[0] (&$function, $cb->[1]); |
358
|
|
|
|
|
|
|
} |
359
|
|
|
|
|
|
|
|
360
|
|
|
|
|
|
|
sub setlocale($;$) { |
361
|
128
|
|
|
128
|
1
|
1328
|
my $function = "Locale::${package}::setlocale"; |
362
|
|
|
|
|
|
|
|
363
|
25
|
|
|
25
|
|
157
|
no strict 'refs'; |
|
25
|
|
|
|
|
65
|
|
|
25
|
|
|
|
|
1731
|
|
364
|
128
|
|
|
|
|
427
|
&$function; |
365
|
|
|
|
|
|
|
} |
366
|
|
|
|
|
|
|
|
367
|
|
|
|
|
|
|
sub nl_putenv($) { |
368
|
530
|
|
|
530
|
1
|
15782
|
my $function = "Locale::${package}::nl_putenv"; |
369
|
|
|
|
|
|
|
|
370
|
25
|
|
|
25
|
|
158
|
no strict 'refs'; |
|
25
|
|
|
|
|
51
|
|
|
25
|
|
|
|
|
2107
|
|
371
|
530
|
|
|
|
|
1500
|
&$function; |
372
|
|
|
|
|
|
|
} |
373
|
|
|
|
|
|
|
|
374
|
|
|
|
|
|
|
sub LC_NUMERIC { |
375
|
0
|
|
|
0
|
1
|
0
|
my $function = "Locale::${package}::LC_NUMERIC"; |
376
|
|
|
|
|
|
|
|
377
|
25
|
|
|
25
|
|
175
|
no strict 'refs'; |
|
25
|
|
|
|
|
38
|
|
|
25
|
|
|
|
|
2253
|
|
378
|
0
|
|
|
|
|
0
|
&$function; |
379
|
|
|
|
|
|
|
} |
380
|
|
|
|
|
|
|
|
381
|
|
|
|
|
|
|
sub LC_CTYPE { |
382
|
0
|
|
|
0
|
1
|
0
|
my $function = "Locale::${package}::LC_CTYPE"; |
383
|
|
|
|
|
|
|
|
384
|
25
|
|
|
25
|
|
162
|
no strict 'refs'; |
|
25
|
|
|
|
|
45
|
|
|
25
|
|
|
|
|
1675
|
|
385
|
0
|
|
|
|
|
0
|
&$function; |
386
|
|
|
|
|
|
|
} |
387
|
|
|
|
|
|
|
|
388
|
|
|
|
|
|
|
sub LC_TIME { |
389
|
0
|
|
|
0
|
1
|
0
|
my $function = "Locale::${package}::LC_TIME"; |
390
|
|
|
|
|
|
|
|
391
|
25
|
|
|
25
|
|
165
|
no strict 'refs'; |
|
25
|
|
|
|
|
51
|
|
|
25
|
|
|
|
|
1563
|
|
392
|
0
|
|
|
|
|
0
|
&$function; |
393
|
|
|
|
|
|
|
} |
394
|
|
|
|
|
|
|
|
395
|
|
|
|
|
|
|
sub LC_COLLATE { |
396
|
0
|
|
|
0
|
1
|
0
|
my $function = "Locale::${package}::LC_COLLATE"; |
397
|
|
|
|
|
|
|
|
398
|
25
|
|
|
25
|
|
185
|
no strict 'refs'; |
|
25
|
|
|
|
|
62
|
|
|
25
|
|
|
|
|
1889
|
|
399
|
0
|
|
|
|
|
0
|
&$function; |
400
|
|
|
|
|
|
|
} |
401
|
|
|
|
|
|
|
|
402
|
|
|
|
|
|
|
sub LC_MONETARY { |
403
|
0
|
|
|
0
|
1
|
0
|
my $function = "Locale::${package}::LC_MONETARY"; |
404
|
|
|
|
|
|
|
|
405
|
25
|
|
|
25
|
|
156
|
no strict 'refs'; |
|
25
|
|
|
|
|
39
|
|
|
25
|
|
|
|
|
3266
|
|
406
|
0
|
|
|
|
|
0
|
&$function; |
407
|
|
|
|
|
|
|
} |
408
|
|
|
|
|
|
|
|
409
|
|
|
|
|
|
|
sub LC_MESSAGES { |
410
|
191
|
|
|
191
|
1
|
19930
|
my $function = "Locale::${package}::LC_MESSAGES"; |
411
|
|
|
|
|
|
|
|
412
|
25
|
|
|
25
|
|
185
|
no strict 'refs'; |
|
25
|
|
|
|
|
71
|
|
|
25
|
|
|
|
|
1567
|
|
413
|
191
|
|
|
|
|
4384
|
&$function; |
414
|
|
|
|
|
|
|
} |
415
|
|
|
|
|
|
|
|
416
|
|
|
|
|
|
|
sub LC_ALL { |
417
|
0
|
|
|
0
|
1
|
|
my $function = "Locale::${package}::LC_ALL"; |
418
|
|
|
|
|
|
|
|
419
|
25
|
|
|
25
|
|
157
|
no strict 'refs'; |
|
25
|
|
|
|
|
43
|
|
|
25
|
|
|
|
|
1643
|
|
420
|
0
|
|
|
|
|
|
&$function; |
421
|
|
|
|
|
|
|
} |
422
|
|
|
|
|
|
|
|
423
|
|
|
|
|
|
|
1; |
424
|
|
|
|
|
|
|
|
425
|
|
|
|
|
|
|
__END__ |