Why UTF-8/16 character encodings?
H. S. Teoh
hsteoh at quickfur.ath.cx
Mon May 27 15:18:31 PDT 2013
On Tue, May 28, 2013 at 12:04:52AM +0200, Vladimir Panteleev wrote:
> On Monday, 27 May 2013 at 21:24:15 UTC, H. S. Teoh wrote:
> >Besides, it's impractical to use compose key sequences to write
> >large amounts of text in some given language; a method of
> >temporarily switching to a different layout is necessary.
>
> I thought the topic was typing the occasional Unicode character to
> use as an operator in D programs?
Well, D *does* support non-English identifiers, y'know... for example:
void main(string[] args) {
int число = 1;
foreach (и; 0..100)
число += и;
writeln(число);
}
Of course, whether that's a good practice is a different story. :)
But for operators, you still need enough compose key sequences to cover
all of the Unicode operators -- and there are a LOT of them -- which I
don't think is currently done anywhere. You'd have to make your own
compose key maps to do it.
T
--
Freedom: (n.) Man's self-given right to be enslaved by his own depravity.
More information about the Digitalmars-d
mailing list