Re: AfxMessageBox?
- From: "David Ching" <dc@xxxxxxxxxxxxxxxxxxxxxx>
- Date: Fri, 24 Nov 2006 17:39:23 GMT
"Mihai N." <nmihai_year_2000@xxxxxxxxx> wrote in message
news:Xns98851565AE8FFMihaiN@xxxxxxxxxxxxxxxx
Because "Hello" and L"Hello" are both standard C/C++.
Making "Hello" to mean Unicode string means the compiler
is not standard compliant.
The MS compilers moved towards being more standard compliant lately
(and is a good thing).
I disagree. MS already has a compiler option to "treat chars as unsigned",
this new option "treat chars as wide" would be the same situation. And the
standards committees could make this a standard also.
Plus there are situations when one might want to use narrow strings
in an Unicode application. If "Hello" means Unicode, then what?
I suggest something like the ATL libraries have used XCHAR and YCHAR. These
change meaning depending on whether UNICODE is defined. XCHAR is like
TCHAR... YCHAR is the opposite of XCHAR, at least I think that's how it
works.
So if UNICODE is defined, "Hello" is Unicode, and Y"Hello" is ANSI. If
UNICODE is not defined, "Hello" is ANSI and Y"Hello" is Unicode. Both of
these are easier to type than _T("").
-- David
.
- Follow-Ups:
- Re: AfxMessageBox?
- From: Mihai N.
- Re: AfxMessageBox?
- References:
- AfxMessageBox?
- From: pvdg42
- Re: AfxMessageBox?
- From: Mihai N.
- Re: AfxMessageBox?
- From: pvdg42
- Re: AfxMessageBox?
- From: Mark Randall
- Re: AfxMessageBox?
- From: David Ching
- Re: AfxMessageBox?
- From: Tom Serface
- Re: AfxMessageBox?
- From: Mihai N.
- Re: AfxMessageBox?
- From: Tom Serface
- Re: AfxMessageBox?
- From: Mihai N.
- Re: AfxMessageBox?
- From: David Ching
- Re: AfxMessageBox?
- From: Mihai N.
- AfxMessageBox?
- Prev by Date: Re: Customize messgbox of window?
- Next by Date: Re: Is it possible to separate the event-handling part from the control?
- Previous by thread: Re: AfxMessageBox?
- Next by thread: Re: AfxMessageBox?
- Index(es):
Relevant Pages
|
Loading