summaryrefslogtreecommitdiff
path: root/dist/Locale-Maketext
diff options
context:
space:
mode:
authorTodd Rinaldo <toddr@cpan.org>2022-04-14 15:27:49 +0000
committerJames E Keenan <jkeenan@cpan.org>2022-04-14 19:30:13 +0000
commitf5469426bb7bc14a72843f9855d2494b01f8df0f (patch)
treedf3fe7902b53350a3e23f737399dc7c2b7a22b84 /dist/Locale-Maketext
parentdb283b77283b2fe01b9b2e53b8f849c1d94fbb7a (diff)
downloadperl-f5469426bb7bc14a72843f9855d2494b01f8df0f.tar.gz
Fix whitespace noise in Locale::MakeText
Bump to 1.31 for release to CPAN. For: https://github.com/Perl/perl5/pull/19581
Diffstat (limited to 'dist/Locale-Maketext')
-rw-r--r--dist/Locale-Maketext/ChangeLog6
-rw-r--r--dist/Locale-Maketext/lib/Locale/Maketext.pm10
-rw-r--r--dist/Locale-Maketext/lib/Locale/Maketext.pod28
-rw-r--r--dist/Locale-Maketext/lib/Locale/Maketext/Cookbook.pod24
-rw-r--r--dist/Locale-Maketext/lib/Locale/Maketext/TPJ13.pod2
-rw-r--r--dist/Locale-Maketext/t/30_eval_dollar_at.t2
-rw-r--r--dist/Locale-Maketext/t/40_super.t6
-rw-r--r--dist/Locale-Maketext/t/50_super.t2
-rw-r--r--dist/Locale-Maketext/t/70_fail_auto.t4
9 files changed, 44 insertions, 40 deletions
diff --git a/dist/Locale-Maketext/ChangeLog b/dist/Locale-Maketext/ChangeLog
index 2edc0aedd9..6051e1c240 100644
--- a/dist/Locale-Maketext/ChangeLog
+++ b/dist/Locale-Maketext/ChangeLog
@@ -1,8 +1,12 @@
Revision history for Perl suite Locale::Maketext
+2022-04-14
+ * Release 1.31 to CPAN
+ * White space cleanup.
+
2022-01-14
* Release 1.30 to CPAN
- * Provide alternate methods allowlist and denylist for
+ * Provide alternate methods allowlist and denylist for
whitelist and blacklist, respectively
2020-01-19
diff --git a/dist/Locale-Maketext/lib/Locale/Maketext.pm b/dist/Locale-Maketext/lib/Locale/Maketext.pm
index ca2242664d..7ad09b785e 100644
--- a/dist/Locale-Maketext/lib/Locale/Maketext.pm
+++ b/dist/Locale-Maketext/lib/Locale/Maketext.pm
@@ -25,7 +25,7 @@ BEGIN {
}
-our $VERSION = '1.30';
+our $VERSION = '1.31';
our @ISA = ();
our $MATCH_SUPERS = 1;
@@ -176,13 +176,13 @@ sub _exclude {
}
sub blacklist {
- my ( $handle, @methods ) = @_;
+ my ( $handle, @methods ) = @_;
_exclude ( $handle, @methods );
return;
}
sub denylist {
- my ( $handle, @methods ) = @_;
+ my ( $handle, @methods ) = @_;
_exclude ( $handle, @methods );
return;
}
@@ -199,13 +199,13 @@ sub _include {
}
sub whitelist {
- my ( $handle, @methods ) = @_;
+ my ( $handle, @methods ) = @_;
_include ( $handle, @methods );
return;
}
sub allowlist {
- my ( $handle, @methods ) = @_;
+ my ( $handle, @methods ) = @_;
_include ( $handle, @methods );
return;
}
diff --git a/dist/Locale-Maketext/lib/Locale/Maketext.pod b/dist/Locale-Maketext/lib/Locale/Maketext.pod
index 3ea5ea478b..761e6abc22 100644
--- a/dist/Locale-Maketext/lib/Locale/Maketext.pod
+++ b/dist/Locale-Maketext/lib/Locale/Maketext.pod
@@ -45,7 +45,7 @@ derive a "project class".
The project class (with a name like "TkBocciBall::Localize",
which you then use in your module) is in turn the base class
for all the "language classes" for your project
-(with names "TkBocciBall::Localize::it",
+(with names "TkBocciBall::Localize::it",
"TkBocciBall::Localize::en",
"TkBocciBall::Localize::fr", etc.).
@@ -122,9 +122,9 @@ If it runs thru the entire given list of language-tags, and finds no classes
for those exact terms, it then tries "superordinate" language classes.
So if no "en-US" class (i.e., YourProjClass::en_us)
was found, nor classes for anything else in that list, we then try
-its superordinate, "en" (i.e., YourProjClass::en), and so on thru
+its superordinate, "en" (i.e., YourProjClass::en), and so on thru
the other language-tags in the given list: "es".
-(The other language-tags in our example list:
+(The other language-tags in our example list:
happen to have no superordinates.)
If none of those language-tags leads to loadable classes, we then
@@ -331,7 +331,7 @@ Bracket Notation or not).
=item $language->quant($number, $singular, $plural, $negative)
This is generally meant to be called from inside Bracket Notation
-(which is discussed later), as in
+(which is discussed later), as in
"Your search matched [quant,_1,document]!"
@@ -482,8 +482,8 @@ to YourProjClass . "::". So this:
'en-US', 'fr', 'kon', 'i-klingon', 'i-klingon-romanized'
);
-will try loading the classes
-YourProjClass::en_us (note lowercase!), YourProjClass::fr,
+will try loading the classes
+YourProjClass::en_us (note lowercase!), YourProjClass::fr,
YourProjClass::kon,
YourProjClass::i_klingon
and YourProjClass::i_klingon_romanized. (And it'll stop at the
@@ -937,13 +937,13 @@ in the "Readonly Lexicons" section.
Methods disallowed by the denylist cannot be permitted by the
allowlist.
-NOTE: denylist() is the preferred method name to use instead of the
-historical and non-inclusive method blacklist(). blacklist() may be
+NOTE: denylist() is the preferred method name to use instead of the
+historical and non-inclusive method blacklist(). blacklist() may be
removed in a future release of this package and so it's use should be
removed from usage.
-NOTE: allowlist() is the preferred method name to use instead of the
-historical and non-inclusive method whitelist(). whitelist() may be
+NOTE: allowlist() is the preferred method name to use instead of the
+historical and non-inclusive method whitelist(). whitelist() may be
removed in a future release of this package and so it's use should be
removed from usage.
@@ -993,7 +993,7 @@ but since you anticipate localizing this, you write:
}
Now, right after you've just written the above lines, you'd
-normally have to go open the file
+normally have to go open the file
ThisProject/I18N/en.pm, and immediately add an entry:
"Couldn't find file \"[_1]\"!\n"
@@ -1224,7 +1224,7 @@ _AUTO lexicon.)
=item *
-Go and write your program. Everywhere in your program where
+Go and write your program. Everywhere in your program where
you would say:
print "Foobar $thing stuff\n";
@@ -1268,7 +1268,7 @@ following phrase.
=item *
-You may at this point want to consider whether your base class
+You may at this point want to consider whether your base class
(Projname::L10N), from which all lexicons inherit from (Projname::L10N::en,
Projname::L10N::es, etc.), should be an _AUTO lexicon. It may be true
that in theory, all needed messages will be in each language class;
@@ -1387,7 +1387,7 @@ I recommend reading all of these:
L<Locale::Maketext::TPJ13|Locale::Maketext::TPJ13> -- my I<The Perl
Journal> article about Maketext. It explains many important concepts
underlying Locale::Maketext's design, and some insight into why
-Maketext is better than the plain old approach of having
+Maketext is better than the plain old approach of having
message catalogs that are just databases of sprintf formats.
L<File::Findgrep|File::Findgrep> is a sample application/module
diff --git a/dist/Locale-Maketext/lib/Locale/Maketext/Cookbook.pod b/dist/Locale-Maketext/lib/Locale/Maketext/Cookbook.pod
index 51fad9528b..f71d71020a 100644
--- a/dist/Locale-Maketext/lib/Locale/Maketext/Cookbook.pod
+++ b/dist/Locale-Maketext/lib/Locale/Maketext/Cookbook.pod
@@ -18,7 +18,7 @@ I<Adapted from a suggestion by Dan Muey>
It may be common (for example at your main lexicon) that
the hash keys and values coincide. Like that
- q{Hello, tell me your name}
+ q{Hello, tell me your name}
=> q{Hello, tell me your name}
It would be nice to just write:
@@ -27,10 +27,10 @@ It would be nice to just write:
and have this magically inflated to the first form.
Among the advantages of such representation, that would
-lead to
-smaller files, less prone to mistyping or mispasting,
-and handy to someone translating it which can simply
-copy the main lexicon and enter the translation
+lead to
+smaller files, less prone to mistyping or mispasting,
+and handy to someone translating it which can simply
+copy the main lexicon and enter the translation
instead of having to remove the value first.
That can be achieved by overriding C<init>
@@ -70,25 +70,25 @@ should be more time expensive as an option.
I<After CPAN RT #36136 (L<https://rt.cpan.org/Ticket/Display.html?id=36136>)>
-The documentation of L<Locale::Maketext> advises that
+The documentation of L<Locale::Maketext> advises that
the standard bracket method C<numf> is limited and that
you must override that for better results. It even
suggests the use of L<Number::Format>.
One such defect of standard C<numf> is to not be
able to use a certain decimal precision.
-For example,
+For example,
$lh->maketext('pi is [numf,_1]', 355/113);
outputs
- pi is 3.14159292035398
+ pi is 3.14159292035398
-Since pi ≈ 355/116 is only accurate
+Since pi ≈ 355/116 is only accurate
to 6 decimal places, you would want to say:
- $lh->maketext('pi is [numf,_1,6]', 355/113);
+ $lh->maketext('pi is [numf,_1,6]', 355/113);
and get "pi is 3.141592".
@@ -132,14 +132,14 @@ like that:
use base qw(Wuu);
-and then
+and then
my $lh = Wuu->get_handle('pt');
$lh->maketext('A [numf,_1,3] km de distância', 1550.2222);
would return "A 1.550,222 km de distância".
-Notice that the standard utility methods of
+Notice that the standard utility methods of
C<Locale::Maketext> are irremediably limited
because they could not aim to do everything
that could be expected from them in different languages,
diff --git a/dist/Locale-Maketext/lib/Locale/Maketext/TPJ13.pod b/dist/Locale-Maketext/lib/Locale/Maketext/TPJ13.pod
index 9ba7a32e04..cb5ef14fd6 100644
--- a/dist/Locale-Maketext/lib/Locale/Maketext/TPJ13.pod
+++ b/dist/Locale-Maketext/lib/Locale/Maketext/TPJ13.pod
@@ -237,7 +237,7 @@ merely needed further consideration.
=over
-"It is more complicated than you think."
+"It is more complicated than you think."
-- The Eighth Networking Truth, from RFC 1925
diff --git a/dist/Locale-Maketext/t/30_eval_dollar_at.t b/dist/Locale-Maketext/t/30_eval_dollar_at.t
index febc2f1b5c..00fbd34d24 100644
--- a/dist/Locale-Maketext/t/30_eval_dollar_at.t
+++ b/dist/Locale-Maketext/t/30_eval_dollar_at.t
@@ -28,7 +28,7 @@ my $err = eval {
$lh->maketext('this is ] an error');
};
is($err, undef, "no return from eval");
-like("$@", qr/Unbalanced\s'\]',\sin/ms, '$@ shows that ] was unbalanced');
+like("$@", qr/Unbalanced\s'\]',\sin/ms, '$@ shows that ] was unbalanced');
# _try_use doesn't pollute $@
$@ = 'foo2';
diff --git a/dist/Locale-Maketext/t/40_super.t b/dist/Locale-Maketext/t/40_super.t
index 8f72687d3c..4def9def57 100644
--- a/dist/Locale-Maketext/t/40_super.t
+++ b/dist/Locale-Maketext/t/40_super.t
@@ -24,17 +24,17 @@ my @in = grep m/\S/, split /[\n\r]/, q{
hai pt-br fr => hai pt-br fr pt
# Now test multi-part complicateds:
- pt-br-janeiro fr => pt-br-janeiro fr pt-br pt
+ pt-br-janeiro fr => pt-br-janeiro fr pt-br pt
pt-br-janeiro de fr => pt-br-janeiro de fr pt-br pt
pt-br-janeiro de pt fr => pt-br-janeiro de pt fr pt-br
-ja pt-br-janeiro fr => ja pt-br-janeiro fr pt-br pt
+ja pt-br-janeiro fr => ja pt-br-janeiro fr pt-br pt
ja pt-br-janeiro de fr => ja pt-br-janeiro de fr pt-br pt
ja pt-br-janeiro de pt fr => ja pt-br-janeiro de pt fr pt-br
pt-br-janeiro de pt-br fr => pt-br-janeiro de pt-br fr pt
# an odd case, since we don't filter for uniqueness in this sub
-
+
};
$Locale::Maketext::MATCH_SUPERS_TIGHTLY = 0;
diff --git a/dist/Locale-Maketext/t/50_super.t b/dist/Locale-Maketext/t/50_super.t
index d253d78da7..ddd9901082 100644
--- a/dist/Locale-Maketext/t/50_super.t
+++ b/dist/Locale-Maketext/t/50_super.t
@@ -44,7 +44,7 @@ my @in = grep m/\S/, split /[\n\r]/, q{
pt-br-janeiro de pt-br fr => pt-br-janeiro de pt-br pt fr
# an odd case, since we don't filter for uniqueness in this sub
-
+
};
sub uniq { my %seen; return grep(!($seen{$_}++), @_); }
diff --git a/dist/Locale-Maketext/t/70_fail_auto.t b/dist/Locale-Maketext/t/70_fail_auto.t
index df0de3eb3c..ac0644174c 100644
--- a/dist/Locale-Maketext/t/70_fail_auto.t
+++ b/dist/Locale-Maketext/t/70_fail_auto.t
@@ -20,8 +20,8 @@ BEGIN {
my $lh = Whunk::L10N->get_handle('en');
$lh->fail_with('failure_handler_auto');
-is($lh->maketext('abcd'), 'abcd', "simple missing keys are handled");
-is($lh->maketext('abcd'), 'abcd', "even in repeated calls");
+is($lh->maketext('abcd'), 'abcd', "simple missing keys are handled");
+is($lh->maketext('abcd'), 'abcd', "even in repeated calls");
# CPAN RT #25877 - $value Not Set After Second Call to failure_handler_auto()
is($lh->maketext('Hey, [_1]', 'you'), 'Hey, you', "keys with bracket notation ok");