![]() |
|
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Programmer
Join Date: Feb 2006
Posts: 36
Rep Power: 0
![]() |
wchar_t and ascii
Hi,
Is it ok to assume that ascii characters have the same value for char and wchar_t types. That is: char 'a' == wchar_t L'a' Bye |
|
|
|
|
|
#2 |
|
I eat cake for breakfast.
![]() ![]() ![]() ![]() Join Date: Jul 2004
Location: In my box.
Posts: 4,434
Rep Power: 9
![]() |
According to the standards, yes, it's fine. However, wchar_t is only required to be at least 8 bits, so you can't necessarily use it for UTF-16 or other two-byte character implementations unless you can guarantee the compiler and OS support it.
|
|
|
|
![]() |
| Bookmarks |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|