Wide Characters

Discussion in 'C++' started by Tomás, Mar 1, 2006.

  1. Tomás

    Tomás Guest

    Is the numerical value for a wide character the same as it is for a
    normal character, by which I mean:

    'a' == static_cast< char > ( L'a' );

    '7' == static_cast< char > ( L'7' );

    'k' == static_cast< char > ( L'k' );

    'w' == static_cast< char > ( L'w' );

    't' == static_cast< char > ( L't' );


    I know that it is on MS Windows, but what about Standard C++?

    -Tomás
     
    Tomás, Mar 1, 2006
    #1
    1. Advertising

  2. Tomás

    peter koch Guest

    Tomás wrote:
    > Is the numerical value for a wide character the same as it is for a
    > normal character, by which I mean:
    >
    > 'a' == static_cast< char > ( L'a' );
    >
    > '7' == static_cast< char > ( L'7' );
    >
    > 'k' == static_cast< char > ( L'k' );
    >
    > 'w' == static_cast< char > ( L'w' );
    >
    > 't' == static_cast< char > ( L't' );
    >
    >
    > I know that it is on MS Windows, but what about Standard C++?


    I doubt that this has been specified. One could imagine e.g. a system
    using EBCDIC for char and some unicode-format for wchar_t.

    /Peter
    >
    > -Tomás
     
    peter koch, Mar 1, 2006
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Web Developer

    char 8bit wide or 7bit wide in c++?

    Web Developer, Jul 31, 2003, in forum: C++
    Replies:
    2
    Views:
    620
    John Harrison
    Jul 31, 2003
  2. Jonathan Mcdougall

    wide characters: "illusion of portability"?

    Jonathan Mcdougall, May 2, 2005, in forum: C++
    Replies:
    3
    Views:
    616
    Jonathan Mcdougall
    May 6, 2005
  3. Disc Magnet
    Replies:
    2
    Views:
    741
    Jukka K. Korpela
    May 15, 2010
  4. Disc Magnet
    Replies:
    2
    Views:
    821
    Neredbojias
    May 14, 2010
  5. Martin Rinehart

    80 columns wide? 132 columns wide?

    Martin Rinehart, Oct 31, 2008, in forum: Javascript
    Replies:
    16
    Views:
    195
    John W Kennedy
    Nov 13, 2008
Loading...

Share This Page