Boost logo

Boost :

From: Beman Dawes (bdawes_at_[hidden])
Date: 2004-10-23 08:01:29


At 07:08 AM 10/23/2004, Andy Little wrote:
>
>The other problem that immediately springs to my mind is , how do I
compose
>a unicode string in my C++ source code. I really dont want to be dealing
>with some unicode_character<TheEncode>(0x78,99,'c',-1) ; style.

The C TR provides additional string literals and character constants. See
below.

--Beman

5.1 String literals and character constants notations

The notations for string literals and character constants for char16_t are
defined analogous to the wide character string literals and wide character
constants:

      u"s-char-sequence"

denotes a char16_t type string literal and initializes an array of
char16_t.

The corresponding character constant is denoted by

      u'c-char-sequence'

and has the type char16_t . Likewise, the string literal and character
constant for char32_t are,

      U"s-char-sequence" and

      U'c-char-sequence'.


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk