www.digitalmars.com         C & C++   DMDScript  

digitalmars.D - What's the encoding of the error message?

reply sailormoontw <sailormoontw_member pathlink.com> writes:
This code: ( Note, aaa.test is not existed )

private import std.file;

void main()
{
read("aaa.test");
}

with the following error message:

F:\d\hdk>dmd test1.d
C:\Dmd\Bin\..\..\dm\bin\link.exe test1,,,user32+kernel32/noi;

F:\d\hdk>test1
Error: aaa.test: 系統?¾ä??°æ?定ç?檔æ???

I cannot read the error message at all...I think it should be English..but why
it shows wierd characters??

Thanks..^_^
May 20 2006
parent reply James Pelcis <jpelcis gmail.com> writes:
The character encoding is UTF8 for sure, but what the characters are is
a different story.

std.file will append the error message returned by Windows.  What
language is Windows set to use?

sailormoontw wrote:
 This code: ( Note, aaa.test is not existed )
 
 private import std.file;
 
 void main()
 +AHs-
 read("aaa.test");
 +AH0-
 
 with the following error message:
 
 F:+AFw-d+AFw-hdk>dmd test1.d
 C:+AFw-Dmd+AFw-Bin+AFw-..+AFw-..+AFw-dm+AFw-bin+AFw-link.exe
test1,,,user32+kernel32/no-;
 
 F:+AFw-d+AFw-hdk>test1
 Error: aaa.test: +/+f/s/+7/+f/tf+x-?+/77/5A-??+/7D/5g-?+/+X/rv+a/+c-?+/+b/qv+U/+Y-???
 
 I cannot read the error message at all...I think it should be English..but why
 it shows wierd characters??
 
 Thanks..+AF4AXwBe-
 
 
May 20 2006
parent reply sailormoontw <sailormoontw_member pathlink.com> writes:
In article <e4nhpk$24kq$1 digitaldaemon.com>, James Pelcis says...
The character encoding is UTF8 for sure, but what the characters are is
a different story.

std.file will append the error message returned by Windows.  What
language is Windows set to use?
In my default Console Mode(MSDos Box that is) it's set to codepage 950, but I cannot find a setting to make it UTF-8. And if I didn't remember wrong, the English charaters in ANSI should be the same as UTF-8, I am not sure why it shows strange characters that doesn't seem to be English.. Thanks for the answer ^_^.
May 20 2006
parent reply James Dunne <james.jdunne gmail.com> writes:
sailormoontw wrote:
 In article <e4nhpk$24kq$1 digitaldaemon.com>, James Pelcis says...
 
The character encoding is UTF8 for sure, but what the characters are is
a different story.

std.file will append the error message returned by Windows.  What
language is Windows set to use?
In my default Console Mode(MSDos Box that is) it's set to codepage 950, but I cannot find a setting to make it UTF-8. And if I didn't remember wrong, the English charaters in ANSI should be the same as UTF-8, I am not sure why it shows strange characters that doesn't seem to be English.. Thanks for the answer ^_^.
'chcp 65001' for UTF-8 output in the command console and use Lucida Console as the raster font to display some Unicode characters. -- Regards, James Dunne
May 20 2006
parent reply Hasan Aljudy <hasan.aljudy gmail.com> writes:
James Dunne wrote:
 sailormoontw wrote:
 
 In article <e4nhpk$24kq$1 digitaldaemon.com>, James Pelcis says...

 The character encoding is UTF8 for sure, but what the characters are is
 a different story.

 std.file will append the error message returned by Windows.  What
 language is Windows set to use?
In my default Console Mode(MSDos Box that is) it's set to codepage 950, but I cannot find a setting to make it UTF-8. And if I didn't remember wrong, the English charaters in ANSI should be the same as UTF-8, I am not sure why it shows strange characters that doesn't seem to be English.. Thanks for the answer ^_^.
'chcp 65001' for UTF-8 output in the command console and use Lucida Console as the raster font to display some Unicode characters.
OFF TOPIC How do you change the code page for the command line interface (dos box)?
May 21 2006
parent Hasan Aljudy <hasan.aljudy gmail.com> writes:
Hasan Aljudy wrote:
 James Dunne wrote:
 
 sailormoontw wrote:

 In article <e4nhpk$24kq$1 digitaldaemon.com>, James Pelcis says...

 The character encoding is UTF8 for sure, but what the characters are is
 a different story.

 std.file will append the error message returned by Windows.  What
 language is Windows set to use?
In my default Console Mode(MSDos Box that is) it's set to codepage 950, but I cannot find a setting to make it UTF-8. And if I didn't remember wrong, the English charaters in ANSI should be the same as UTF-8, I am not sure why it shows strange characters that doesn't seem to be English.. Thanks for the answer ^_^.
'chcp 65001' for UTF-8 output in the command console and use Lucida Console as the raster font to display some Unicode characters.
OFF TOPIC How do you change the code page for the command line interface (dos box)?
wops, never mind! chcp
May 21 2006