Re: Unicode characters in identifiers
- From: "R.Kaiser" <rk@xxxxxxxxxxxxxxxxxx>
- Date: Wed, 16 Aug 2006 19:01:26 +0200
Thanks Vladimir,
I have overlooked the reference to Annex E in the standard.
Richard
Vladimir Nesterovsky schrieb:
.Where can I find which Unicode characters are valid for identifiers inAccording to the VC++ documentation:
Visual C++ 2005?
...
More accurate definition according to the spec is:
2.10 Identifiers [lex.name]
identifier:
nondigit
identifier nondigit
identifier digit
nondigit: one of
universal-character-name
_ a b c d e f g h i j k l m
n o p q r s t u v w x y z
A B C D E F G H I J K L M
N O P Q R S T U V W X Y Z
digit: one of
0 1 2 3 4 5 6 7 8 9
1 An identifier is an arbitrarily long sequence of letters and digits. Each universal-character-name in an identifier shall designate a character whose encoding in ISO 10646 falls into one of the ranges specified in Annex E. Upper- and lower-case letters are different. All characters are significant.
2 In addition, some identifiers are reserved for use by C++ implementations and standard libraries (17.4.3.1.2) and shall not be used otherwise; no diagnostic is required.
This means that national characters can be a part of a name. I've tested Russian and Hebrew characters. It's worked.
--
Vladimir Nesterovsky
- References:
- Unicode characters in identifiers
- From: R.Kaiser
- Re: Unicode characters in identifiers
- From: Carl Daniel [VC++ MVP]
- Re: Unicode characters in identifiers
- From: Vladimir Nesterovsky
- Unicode characters in identifiers
- Prev by Date: Re: need some help with list::end ()
- Next by Date: Re: Unicode characters in identifiers
- Previous by thread: Re: Unicode characters in identifiers
- Next by thread: Re: Unicode characters in identifiers
- Index(es):
Relevant Pages
|