[Issue 11275] New: Constants for setlocale are incorrect

d-bugmail at puremagic.com d-bugmail at puremagic.com
Tue Oct 15 13:23:41 PDT 2013


http://d.puremagic.com/issues/show_bug.cgi?id=11275

           Summary: Constants for setlocale are incorrect
           Product: D
           Version: D2
          Platform: All
        OS/Version: Windows
            Status: NEW
          Severity: normal
          Priority: P2
         Component: druntime
        AssignedTo: nobody at puremagic.com
        ReportedBy: frank.deprins at skynet.be


--- Comment #0 from Frank De prins <frank.deprins at skynet.be> 2013-10-15 13:23:40 PDT ---
The LC_xxx constants, defined in core.stdc.locale are not correct, at least not
for Windows.
In the headers of Microsoft Visual C++, as well as in other windows based
compilers, these are defined as:

#define LC_ALL          0
#define LC_COLLATE      1
#define LC_CTYPE        2
#define LC_MONETARY     3
#define LC_NUMERIC      4
#define LC_TIME         5

whereas, in core.stdc.locale, they are defined as:

enum LC_CTYPE          = 0;
enum LC_NUMERIC        = 1;
enum LC_TIME           = 2;
enum LC_COLLATE        = 3;
enum LC_MONETARY       = 4;
enum LC_ALL            = 6;

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------


More information about the Digitalmars-d-bugs mailing list