stdcxx-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Apache Wiki <wikidi...@apache.org>
Subject [Stdcxx Wiki] Update of "LocaleLookup" by MartinSebor
Date Mon, 18 Feb 2008 23:54:23 GMT
Dear Wiki user,

You have subscribed to a wiki page or wiki category on "Stdcxx Wiki" for change notification.

The following page has been changed by MartinSebor:
http://wiki.apache.org/stdcxx/LocaleLookup

The comment on the change is:
Updated Problem Statement and added Objective.

------------------------------------------------------------------------------
  
  = Problem Statement =
  
- Modern operating systems provide support for dozens or even hundreds locales. The set of
locales installed on a computer is typically determined by the system administrator at the
time the operating system is installed. Although there are standards and conventions in place
to establish a common locales names due to historical reasons locale names tend to vary from
one implementation to another. Operating systems may provide the standard names as well as
the traditional ones, with the former simply being aliases for the latter.
+ Modern operating systems provide support for dozens or even hundreds locales encoded in
various codesets. The set of locales and codesets installed on a computer is typically determined
by the system administrator at the time the operating system is installed. Although there
are standards and conventions in place to establish a common set of locale names, due to historical
reasons both locale and codeset names tend to vary from one implementation to another. Operating
systems may provide the standard names as well as the traditional ones, with the former simply
being aliases for the latter.
  
- The stdcxx test suite contains tests that exercise the behavior of the localization library.
Since the set of installed locales may vary from server to server and since their names need
not be consistent across different operating systems, the test stdcxx driver provides mechanisms
to determine the names of all locales known to a system. For simplicity, the tests exercise
the localization library in all these locales. On systems with many locales installed running
these tests may take a considerable amount of time and use up valuable system resources. For
example, on AIX systems with all available locales installed running each test can take as
much as an hour. Since many of the locale names reference the same locale exercising all of
them is wasteful. In addition, since many locales differ only in very minor details (e.g.,
the values of punctuator characters), exhaustively testing all of them ends up repeatedly
executing the same code paths and is unnecessary.
+ The stdcxx test suite contains tests that exercise the behavior of the localization library.
Since the set of installed locales may vary from server to server and since their names need
not be consistent across different operating systems, the test stdcxx driver provides mechanisms
to determine the names of all locales known to a system. For simplicity, many tests exercise
the localization library using all these locale names. Other tests do so in an effort to exercise
different code paths taken based on whether a locale uses a single-byte or multi-byte encoding.
On systems with many installed locales running these tests may take a considerable amount
of time and use up valuable system resources. For example, on AIX systems with all available
locales installed running each test can take as much as an hour. In addition, since many of
the locale names reference the same locale exercising all of them is wasteful. In addition,
since many locales differ only in very minor detail
 s (e.g., the values of punctuator characters), exhaustively testing all of them ends up repeatedly
executing the same code paths and is unnecessary.
+ 
+ = Objective =
+ 
+ The objective of this project is to provide an interface to make it easy to write localization
tests without the knowledge of platform-specific details that provide sufficient code coverage
and that complete in a reasonable amount of time (ideally seconds as opposed to minutes).
The interface must make it easy to query the system for locales that satisfy the specific
requirements of each test. For example, most tests that currently use all installed locales
(e.g., the set of tests for the `std::ctype` facet) only need to exercise a representative
sample of the installed locales without using the same locale more than once. Thus the interface
will need to make it possible to specify such a sample. Another example is tests that attempt
to exercise locales in multibyte encodings whose `MB_CUR_MAX` ranges from 1 to 6 (some of
the `std::codecvt` facet tests). The new interface will need to make it easy to specify such
a set of locales without explicitly naming them, and it will 
 need to retrieve such locales without returning duplicates.
  
  = Definitions =
  

Mime
View raw message