Thread overview
Unicode ideas
Sep 20, 2001
Eric Gerlach
Sep 21, 2001
Walter
Sep 21, 2001
Axel Kittenberger
September 20, 2001
Hello all,

I truly hate being off-line for several weeks.  There are tons of things I want to reply to (only a fraction of which I'll get to I'm sure), but here's something I've been thinking about recently which has had me quite enthusiastic about D.

Unicode.

Unicode is a very powerful tool.  Right now it's just sitting on the sidelines of D.  You can use it, but the language doesn't really know what to do with it.  I've come up with a couple of ideas that could significantly increase the power of D.  What do people think of the following:

- Expanding the allowable alphabet for variable names to include parts of other character sets
- Having translated keywords in other languages (ex: having katakana translations for 'if', 'else', etc.)
- (I've mentionned this already) Using the Unicode mathematical operators for operator overloading
- Having a roman numerals parser (there are roman numeral characters in Unicode!!)

I'm sure there are other powerful uses for Unicode in D that I haven't thought of.  It's really a powerful addition to the language.  How many of these things have been considered?

Cheers,

Eric

September 21, 2001
Eric Gerlach wrote in message <3BAA4D5E.70402@canada.com>...
>Hello all,
>
>I truly hate being off-line for several weeks.  There are tons of things I want to reply to (only a fraction of which I'll get to I'm sure), but here's something I've been thinking about recently which has had me quite enthusiastic about D.
>
>Unicode.
>
>Unicode is a very powerful tool.  Right now it's just sitting on the sidelines of D.  You can use it, but the language doesn't really know what to do with it.  I've come up with a couple of ideas that could significantly increase the power of D.  What do people think of the following:
>
>- Expanding the allowable alphabet for variable names to include parts
>of other character sets
>- Having translated keywords in other languages (ex: having katakana
>translations for 'if', 'else', etc.)
>- (I've mentionned this already) Using the Unicode mathematical
>operators for operator overloading
>- Having a roman numerals parser (there are roman numeral characters in
>Unicode!!)
>
>I'm sure there are other powerful uses for Unicode in D that I haven't thought of.  It's really a powerful addition to the language.  How many of these things have been considered?
>
>Cheers,
>
>Eric


While things like keywords in katakana is possible and in fact easy to implement, I'm not sure if it makes much sense. In my experience, Japanese computer engineers are accustomed to english technical words, because of this I've been able to use Japanese technical manuals written in Japanese despite not knowing a word of Japanese.


September 21, 2001
> - Expanding the allowable alphabet for variable names to include parts of other character sets

question: 16 bit or 32 bit Unicode?

> - Having translated keywords in other languages (ex: having katakana translations for 'if', 'else', etc.)

I used to program Microsoft Access databases in my dark past. Okay I was young and I needed the money :o) But well the ms officage just has this "nice" feature, that localisation also includes the commandos, and living in germany we've usually mixed installations of german and english software. They german ones understood commandos like "schalte" instead of "switch", "wenn" instead of "if". etc. I think one can easily imagine the horrors that can be created when some scripts work well on computer A but fails on computer B.

Imagine you've one day to debug localized "C" like this
-----
#einbeziehe <stdio.h>

nichts haupt(ganz argc, ganz* argv[])
{
  ganz i = 1;
  schreibef("hallo welt\n");
  mache {
        i *= 2;
        schreibef("%d", i);
        schalte (i) {
                fall 8  : schreibef("- acht\n"); abbreche;
                ansonst : schreibef("\n"); abbreche;
        }
  } während( i < 100);
  zurückbege;
}

----

I don't see what the advantage for a german reader would be, yet what an english would think.

> - (I've mentionned this already) Using the Unicode mathematical
> operators for operator overloading

If you allow unicode for variable names also, you've again the old conflict, whats an operater, whats a variable.

> - Having a roman numerals parser (there are roman numeral characters in
> Unicode!!)

Any possilbe -real- uses for this? instead of helping obfusication contests :/

- Axel