t/loc_tools.pl: Add some locale finding for Win32
authorKarl Williamson <public@khwilliamson.com>
Tue, 21 Jan 2014 23:01:48 +0000 (16:01 -0700)
committerKarl Williamson <public@khwilliamson.com>
Wed, 22 Jan 2014 18:45:59 +0000 (11:45 -0700)
This is based on the documentation in
http://msdn.microsoft.com/en-us/library/hzz3tw78.aspx
and linked-to pages.

We try out new locale combinations to see if they are found.

t/loc_tools.pl

index 98af329..45377a0 100644 (file)
@@ -40,12 +40,16 @@ sub _decode_encodings {
            }
            push @enc, $_;
             push @enc, "$_.UTF-8";
+            push @enc, "$_.65001"; # Windows UTF-8
+            push @enc, "$_.ACP"; # Windows ANSI code page
+            push @enc, "$_.OCP"; # Windows OEM code page
        }
     }
     if ($^O eq 'os390') {
        push @enc, qw(IBM-037 IBM-819 IBM-1047);
     }
     push @enc, "UTF-8";
+    push @enc, "65001"; # Windows UTF-8
 
     return @enc;
 }