Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
We're skipping inclusion of some files such as the unused Build.PL, INSTALL, etc. cpan/Locale-Codes/internal/* should probably also not be included in perl core.
- Loading branch information
Showing
53 changed files
with
29,532 additions
and
3,233 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
This module is free software; you can redistribute it and/or | ||
modify it under the same terms as Perl itself. | ||
|
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
|
||
Locale-Codes Distribution | ||
|
||
For changes in this release, please refer to the Locale::Changes | ||
man-page. | ||
|
||
For changes prior to 3.00, please see the ChangeLog file. | ||
|
||
This distribution contains Perl modules which can be used to process | ||
ISO codes for identifying languages, countries, scripts, | ||
and currencies & funds. | ||
|
||
Locale::Language | ||
|
||
Codes for language identification including ISO 639. | ||
|
||
For example, 'en' is the code for 'English'. | ||
|
||
Locale::Country | ||
|
||
Codes for country identification including ISO 3166 | ||
and FIPS 10. | ||
|
||
For example, 'us' is the code for 'United States'. | ||
|
||
Locale::Currency | ||
|
||
Codes for currency and fund identification including | ||
ISO 4217. | ||
|
||
For example, 'sek' is the code for 'Swedish Krona'. | ||
|
||
Locale::Script | ||
|
||
Codes for script identification including ISO 15924. | ||
|
||
For example, 'Phnx' is the code for 'Phoenician'. | ||
|
||
The modules are documented using pod. When you "make install", you | ||
will get man-pages: Local::Codes and each of the modules listed above. | ||
|
||
The first version of Locale::Currency was written by Michael Hennecke, | ||
with modifications by Neil Bowers for inclusion. | ||
|
||
The first versions of Locale::Language, Locale::Country, and Locale::Script | ||
were written by Neil Bowers. | ||
|
||
Please let me know if you experience any problems with these modules, | ||
or have any ideas for additions. | ||
|
||
Also, I plan on releasing a new version a couple of times a year to make | ||
sure that all of the codes are current. If a code changes in any standard, | ||
and you want a new release, just email me and I'll put out a new release. | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,96 @@ | ||
Please refer to the ../t directory for examples of how to use this | ||
module. | ||
|
||
The tests are organized fairly simply. In each .t file (except for | ||
pod and pod_coverage) is a line of the form: | ||
|
||
test_Func(\&FUNC,$tests,$runtests,ARGS) | ||
|
||
FUNC is the name of one of the functions available in the module, | ||
or some function defined in the test script which calls one or more | ||
of the module functions. | ||
|
||
Also in the file are a series of tests organized as: | ||
|
||
$tests = " | ||
TEST1 | ||
|
||
TEST2 | ||
|
||
... | ||
"; | ||
|
||
or | ||
|
||
$tests = [ | ||
TEST1, | ||
|
||
TEST2, | ||
|
||
... ]; | ||
|
||
|
||
In the first case, a test is a list of strings, some of which are used | ||
as arguments for the function being called, and some are expected results. | ||
If the expected result is a simple scalar, each TEST may be a simple list | ||
of space separated strings, the last of which is treated as the expected | ||
output. | ||
|
||
For example, if the following line appears in the test script: | ||
|
||
test_Func(\&somefunc,$tests,$runtests); | ||
|
||
and one of the tests is: | ||
|
||
A B C | ||
|
||
then the following behavior is expected: | ||
|
||
somefunc(A,B) | ||
=> C | ||
|
||
The list of strings may also be given on separate lines as: | ||
|
||
A | ||
B | ||
C | ||
|
||
If the expected results are a list of values, then the arguments | ||
to the function and the expected results are separated by a tilde (~). | ||
So if the following behavior is expected: | ||
|
||
somefunc(A,B) | ||
=> (C,D) | ||
|
||
the test could be written in either of the following ways: | ||
|
||
A B ~ C D | ||
|
||
A | ||
B | ||
~ | ||
C | ||
D | ||
|
||
In all cases, leading spaces are ignored. Also, the strings may include | ||
spaces if (and only if) they are given one per line. | ||
|
||
Two special strings "_undef_" and "_blank_" may be included in the list | ||
to have the values undef or "" repectively included as either an argument | ||
or an expected return value. | ||
|
||
|
||
In the second method of entering tests, tests are given as a list reference | ||
with two values. The first is a list reference containing arguments, and | ||
the second is a list reference containing the expected return value(s). The | ||
expected values should be simple strings. | ||
|
||
So, a test could be entered as: | ||
|
||
[ [ qw(A B) ], | ||
[ qw(C D) ] ] | ||
|
||
and be equivalent to: | ||
|
||
A B ~ C D | ||
|
Oops, something went wrong.