Re: [Lazarus] Proposal: Allow Umlaute and Accented Characters in Identifiers

2020-07-05 Thread Jean SUZINEAU via lazarus

Le 06/07/2020 à 00:04, Marco van de Voort via lazarus a écrit :

Op 2020-07-05 om 22:17 schreef Jean SUZINEAU via lazarus:
My post is close to off topic, but I've seen recently a paper on 
arXiv proposing to use Chinese characters for logic operators ...

When, April 1st? :-)
:-)  Not far away, April 15th according to arXiv watermarks on the 
pdf    ...

--
___
lazarus mailing list
lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Proposal: Allow Umlaute and Accented Characters in Identifiers

2020-07-05 Thread Marco van de Voort via lazarus


Op 2020-07-05 om 22:17 schreef Jean SUZINEAU via lazarus:
My post is close to off topic, but I've seen recently a paper on arXiv 
proposing to use Chinese characters for logic operators ...


When, April 1st? :-)


--
___
lazarus mailing list
lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Proposal: Allow Umlaute and Accented Characters in Identifiers

2020-07-05 Thread Ralf Quint via lazarus

On 7/5/2020 1:17 PM, Jean SUZINEAU via lazarus wrote:
My post is close to off topic, but I've seen recently a paper on arXiv 
proposing to use Chinese characters for logic operators ...


The keyword for AND would be 与
The  NOT :  非
The XOR:  异或
The boolean OR:  规约或
The bitwise OR:  按位或

;-)

https://arxiv.org/pdf/2004.10675.pdf


Yeah, a surefire way to create completely unmaintainable code... SMH

Ralf



--
This email has been checked for viruses by Avast antivirus software.
https://www.avast.com/antivirus

--
___
lazarus mailing list
lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Proposal: Allow Umlaute and Accented Characters in Identifiers

2020-07-05 Thread Jean SUZINEAU via lazarus
My post is close to off topic, but I've seen recently a paper on arXiv 
proposing to use Chinese characters for logic operators ...


The keyword for AND would be 与
The  NOT :  非
The XOR:  异或
The boolean OR:  规约或
The bitwise OR:  按位或

;-)

https://arxiv.org/pdf/2004.10675.pdf

--
___
lazarus mailing list
lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Proposal: Allow Umlaute and Accented Characters in Identifiers

2020-07-05 Thread Mattias Gaertner via lazarus
On Sun, 5 Jul 2020 13:22:40 +0200
"R.Smith via lazarus"  wrote:

> > Very interesting, Graeme. Exactly this could significantly improve 
> > Lazarus.  
> 
> 
> This thread keeps mentioning "Lazarus" and how it will improve
> "Lazarus"...
> 
> Does Lazarus even have a say in this?
> 
> Surely this is solely up to FPC?

You can open Delphi units in Lazarus. It would be good to support
at least some Unicode identifiers.

Mattias

-- 
___
lazarus mailing list
lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Proposal: Allow Umlaute and Accented Characters in Identifiers

2020-07-05 Thread R.Smith via lazarus


Very interesting, Graeme. Exactly this could significantly improve 
Lazarus.



This thread keeps mentioning "Lazarus" and how it will improve "Lazarus"...

Does Lazarus even have a say in this?

Surely this is solely up to FPC?


--
___
lazarus mailing list
lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Proposal: Allow Umlaute and Accented Characters in Identifiers

2020-07-05 Thread Marco van de Voort via lazarus


Op 2020-07-04 om 23:13 schreef Sven Barth via lazarus:


The Unicode Standard I had linked yesterday evening already, cause I 
knew that one existed, but I didn't know about the ISO/IEC one...


The ISO standard is about making formal language specifications. The 
unicode relevant bit seems to be only the annex.

--
___
lazarus mailing list
lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Proposal: Allow Umlaute and Accented Characters in Identifiers

2020-07-05 Thread Sven Barth via lazarus
Graeme Geldenhuys via lazarus  schrieb am
So., 5. Juli 2020, 01:38:

> On 04/07/2020 9:48 pm, Sven Barth via lazarus wrote:
> > I've just tested: Delphi does not support Emojis.
>
> I've just tested with Java. They allow Unicode, but only what is
> considered "spoken language" characters. So things like Emojis, Math
> Symbols, Arrows etc are not allowed as part of the text making up
> the identifier's name.
>

They probably follow the same standard.

Regards,
Sven

>
-- 
___
lazarus mailing list
lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Proposal: Allow Umlaute and Accented Characters in Identifiers

2020-07-05 Thread Hans-Georg Joepgen via lazarus

Am 05.07.2020 um 01:37 schrieb Graeme Geldenhuys via lazarus:

On 04/07/2020 9:48 pm, Sven Barth via lazarus wrote:

I've just tested: Delphi does not support Emojis.

I've just tested with Java. They allow Unicode, but only what is
considered "spoken language" characters. So things like Emojis, Math
Symbols, Arrows etc are not allowed as part of the text making up
the identifier's name.


Regards,
   Graeme



Very interesting, Graeme. Exactly this could significantly improve Lazarus.

--   Joe


--
___
lazarus mailing list
lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Proposal: Allow Umlaute and Accented Characters in Identifiers

2020-07-04 Thread Graeme Geldenhuys via lazarus
On 04/07/2020 9:48 pm, Sven Barth via lazarus wrote:
> I've just tested: Delphi does not support Emojis. 

I've just tested with Java. They allow Unicode, but only what is
considered "spoken language" characters. So things like Emojis, Math
Symbols, Arrows etc are not allowed as part of the text making up
the identifier's name.


Regards,
  Graeme

-- 
fpGUI Toolkit - a cross-platform GUI toolkit using Free Pascal
http://fpgui.sourceforge.net/

My public PGP key:  http://tinyurl.com/graeme-pgp
-- 
___
lazarus mailing list
lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Proposal: Allow Umlaute and Accented Characters in Identifiers

2020-07-04 Thread Sven Barth via lazarus

Am 04.07.2020 um 22:56 schrieb Marco van de Voort via lazarus:


Op 2020-07-04 om 22:48 schreef Sven Barth via lazarus:

Am 04.07.2020 um 20:13 schrieb Graeme Geldenhuys via lazarus:

On 04/07/2020 7:11 pm, Graeme Geldenhuys via lazarus wrote:

var
    : Integer;
begin
    for  := 0 to 10 do
  writeln();
end.


And exception variables could be 濫  (nauseated face).


I've just tested: Delphi does not support Emojis. According to their 
documentation ( 
http://docwiki.embarcadero.com/RADStudio/Sydney/en/Identifiers ) they 
adhere to ISO/IEC TR 10176:2003 ( 
https://www.iso.org/standard/37765.html ). Sadly this standard isn't 
freely available to check what is allowed and what not :/


Seems C++ (23) committee has that problem too 
http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2019/p1949r0.html 
they refer to the relevant annex that seems to be available 
https://unicode.org/reports/tr31/


The Unicode Standard I had linked yesterday evening already, cause I 
knew that one existed, but I didn't know about the ISO/IEC one...


Regards,
Sven
--
___
lazarus mailing list
lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Proposal: Allow Umlaute and Accented Characters in Identifiers

2020-07-04 Thread Marco van de Voort via lazarus


Op 2020-07-04 om 22:48 schreef Sven Barth via lazarus:

Am 04.07.2020 um 20:13 schrieb Graeme Geldenhuys via lazarus:

On 04/07/2020 7:11 pm, Graeme Geldenhuys via lazarus wrote:

var
    : Integer;
begin
    for  := 0 to 10 do
  writeln();
end.


And exception variables could be 濫  (nauseated face).


I've just tested: Delphi does not support Emojis. According to their 
documentation ( 
http://docwiki.embarcadero.com/RADStudio/Sydney/en/Identifiers ) they 
adhere to ISO/IEC TR 10176:2003 ( 
https://www.iso.org/standard/37765.html ). Sadly this standard isn't 
freely available to check what is allowed and what not :/


Seems C++ (23) committee has that problem too 
http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2019/p1949r0.html 
they refer to the relevant annex that seems to be available 
https://unicode.org/reports/tr31/



--
___
lazarus mailing list
lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Proposal: Allow Umlaute and Accented Characters in Identifiers

2020-07-04 Thread Sven Barth via lazarus

Am 04.07.2020 um 20:13 schrieb Graeme Geldenhuys via lazarus:

On 04/07/2020 7:11 pm, Graeme Geldenhuys via lazarus wrote:

var
: Integer;
begin
for  := 0 to 10 do
  writeln();
end.


And exception variables could be 濫  (nauseated face).


I've just tested: Delphi does not support Emojis. According to their 
documentation ( 
http://docwiki.embarcadero.com/RADStudio/Sydney/en/Identifiers ) they 
adhere to ISO/IEC TR 10176:2003 ( 
https://www.iso.org/standard/37765.html ). Sadly this standard isn't 
freely available to check what is allowed and what not :/


Regards,
Sven
--
___
lazarus mailing list
lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Proposal: Allow Umlaute and Accented Characters in Identifiers

2020-07-04 Thread Graeme Geldenhuys via lazarus
On 04/07/2020 7:11 pm, Graeme Geldenhuys via lazarus wrote:
> var
>: Integer;
> begin
>for  := 0 to 10 do
>  writeln();
> end.


And exception variables could be 濫  (nauseated face).


Regards,
  Graeme

-- 
fpGUI Toolkit - a cross-platform GUI toolkit using Free Pascal
http://fpgui.sourceforge.net/

My public PGP key:  http://tinyurl.com/graeme-pgp
-- 
___
lazarus mailing list
lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Proposal: Allow Umlaute and Accented Characters in Identifiers

2020-07-04 Thread Graeme Geldenhuys via lazarus
On 03/07/2020 3:37 pm, Michael Van Canneyt via lazarus wrote:
> I did a quick test in Delphi:

If Unicode is indeed supported in the language itself, it would
be hilarious to start seeing coding using emojis as identifiers!
:-D

https://unicode.org/emoji/charts/full-emoji-list.html


var
   : Integer;
begin
   for  := 0 to 10 do
 writeln();
end.


Regards,
  Graeme

-- 
fpGUI Toolkit - a cross-platform GUI toolkit using Free Pascal
http://fpgui.sourceforge.net/

My public PGP key:  http://tinyurl.com/graeme-pgp
-- 
___
lazarus mailing list
lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Proposal: Allow Umlaute and Accented Characters in Identifiers

2020-07-04 Thread Vincenzo Campanella via lazarus


Il 03.07.2020 18:44, Dmitry Boyarintsev via lazarus ha scritto:
On Fri, Jul 3, 2020 at 10:08 AM Special via lazarus 
mailto:lazarus@lists.lazarus-ide.org>> 
wrote:


on a Elementary  School near Heidelberg the nine-years-old pupils
learn
programming with Delphi 10.3 Community Edition. In one of the
programs
they use 'Type ZimmerType = (Küche, Wohnzimmer, Schlafzimmer);",


Having educational purposes in mind, can variable masking be 
achieved through IDE itself, rather than the compiler.


If a character outside of ANSI range is met within an identifier, IDE 
would replace it with something else.
So, instead of having "Küche" the source code would look like 
"K_Ache". (the next character would be replaced with _B, _C ..and so on)


It doesn't have to be done on the fly, it could be done before 
starting the compilation.

There are two benefits with this approach:
* no changes are needed for the compiler. (works with any version)
* the language rules of capitalization can be followed

Living in Switzerland, where German is one of the national languages, we 
oft face problems like this.


In this case, we simply substitute "ä" with "ae", "ö" with "oe" and "ü" 
with "ue". So: Küche -> Kueche. And: "ß" -> "ss".


Freundliche Grüße aus der Schweiz :)


-- 
___
lazarus mailing list
lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Proposal: Allow Umlaute and Accented Characters in Identifiers

2020-07-04 Thread Florian Klämpfl via lazarus


> Am 03.07.2020 um 14:09 schrieb Special via lazarus 
> :
> 
> Hi,
> 
> we have many Delphi programs with identifiers containing parts like 'Köln' 
> and 'Liège'. These programs we want to convert to Lazarus. Unfortunately, 
> Lazarus (or FP) seems not to be able to use identifiers with umlaute and 
> accents. Maybe the reason for this could be pure historical and stem from the 
> pre Unicode epoche.
> 
> Manually chanching all those identifiers and modifying the references to them 
> is not very elegant. By the way: Using the international names of cities 
> instead of their orginal names introduces new difficulties. The international 
> name of 'München', for instance, is 'Monaco', the same name as that for the 
> Grimaldi Imperium.
> 
> Circumscribing is also no option. The name of Müllerstadt is 'Müllerstadt' 
> and not 'Muellerstadt'.

Nevertheless German is a bad reason in this case. I think almost every German 
knows that e.g. the umlauts are often replaced by ae, oe, ue. All my email 
addresses are still using Klaempfl instead of Klämpfl. And actually everybody 
does this right.

> 
> Could Lazarus (and/or maybe Free Pascal) be improved to tolerate those 
> identfiers?
> 
> Regards  --  Joe
> -- 
> ___
> lazarus mailing list
> lazarus@lists.lazarus-ide.org
> https://lists.lazarus-ide.org/listinfo/lazarus

-- 
___
lazarus mailing list
lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Proposal: Allow Umlaute and Accented Characters in Identifiers

2020-07-04 Thread Michael Van Canneyt via lazarus



On Sat, 4 Jul 2020, Special via lazarus wrote:


Am 03.07.2020 um 16:13 schrieb Martin Frb via lazarus:

On 03/07/2020 14:55, Péter Gábor via lazarus wrote:

Hi!

Then you must allow Cyrillic,d Arabic and so Chinese and other national
and special characters to be used in identifiers.
Worse, the same source may then compile or fail to compile depending on the 
locale.


Pascal is case insensitive.
var I: integer; // upper i
...
for i := 0 to x do ...;

compiles today.

But when compiling, using Turkish locale, this would fail.
In Turkish there is a dotted and a dotless i, both upper and lower.
So I and i are different letters.
https://en.wikipedia.org/wiki/Dotted_and_dotless_I


Hi,

if Lazarus had an option "Allow accented Latin characters and Umlauts in 
identifiers", then Cyrillic, Arabic and Chinese and other special national 
charcters and dotted characters like the Turkish "I." were not included 
('Dotted' is not 'Accented').  So we could enjoy the benefits of this 
proposal without the drawbacks.


Sorry, I don't think this is right.

Why should Russian, Chinese or Arabic or any non-latin alphabet students 
be disadvantaged compared to western students ?


Either you allow them all (with all that implies) or none (as it is now).

Michael.-- 
___
lazarus mailing list
lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Proposal: Allow Umlaute and Accented Characters in Identifiers

2020-07-03 Thread Dmitry Boyarintsev via lazarus
On Fri, Jul 3, 2020 at 12:44 PM Dmitry Boyarintsev <
skalogryz.li...@gmail.com> wrote:

> Having educational purposes in mind, can variable masking be
> achieved through IDE itself, rather than the compiler.
>

Yes, i do realize that it might get worse when it comes to debugging, where
the same masking technique will have to be used.

thanks,
Dmitry
-- 
___
lazarus mailing list
lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Proposal: Allow Umlaute and Accented Characters in Identifiers

2020-07-03 Thread Dmitry Boyarintsev via lazarus
On Fri, Jul 3, 2020 at 10:08 AM Special via lazarus <
lazarus@lists.lazarus-ide.org> wrote:

> on a Elementary  School near Heidelberg the nine-years-old pupils learn
> programming with Delphi 10.3 Community Edition. In one of the programs
> they use 'Type ZimmerType = (Küche, Wohnzimmer, Schlafzimmer);",
>

Having educational purposes in mind, can variable masking be
achieved through IDE itself, rather than the compiler.

If a character outside of ANSI range is met within an identifier, IDE would
replace it with something else.
So, instead of having "Küche" the source code would look like "K_Ache".
(the next character would be replaced with _B, _C ..and so on)

It doesn't have to be done on the fly, it could be done before starting the
compilation.
There are two benefits with this approach:
* no changes are needed for the compiler. (works with any version)
* the language rules of capitalization can be followed

thanks,
Dmitry
-- 
___
lazarus mailing list
lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Proposal: Allow Umlaute and Accented Characters in Identifiers

2020-07-03 Thread Sven Barth via lazarus
Martin Frb via lazarus  schrieb am Fr., 3.
Juli 2020, 17:02:

> On 03/07/2020 16:37, Michael Van Canneyt via lazarus wrote:
> >
> >
> > On Fri, 3 Jul 2020, Martin Frb via lazarus wrote:
> >
> >> On 03/07/2020 16:21, Péter Gábor via lazarus wrote:
> >>> Hi!
> >>>
> >>> I hope that you did not misread my words/sentences.
> >>> Your example if perfect to illustrate the reason why I don't want
> >>> international characters in the language itself (and identifiers).
> >> Yes, that was my understanding.
> >>
> >> You gave reasons why it would be a bad idea. I added a reason, that I
> >> think would make the idea even worse.
> >> In other words, I supported the current a-z0-1_ set.
> >
> > I did a quick test in Delphi:
> >
> >
> > [dcc32 Error] doti.dpr(9): E2003 Undeclared identifier: 'ß'
> >
> > So indeed, case-insensitivity is lost. Even in German.
>
> And that, despite the German ß is not locale dependent. It has exactly
> one uppercase version.
> Were as "i" has 2. (But not within any one locale)
>
> I would guess that if you copy and paste, and some of your umlauts/chars
> are composed, some decomposed, that will likely not work either.
> And for composed chars with more than one combining codepoint, if the
> order of the combining codepoints does not matter, the problem will
> likely be the same.
>
> Then there are full width codepoint for some chars. (They could be
> argued to be ignored, but readability would be gone...)
> https://en.wikipedia.org/wiki/Halfwidth_and_Fullwidth_Forms_(Unicode_block)
> So "A" and "A" should also be the same.
> And full width digits should be allowed in numbers.
>
> I do wonder, if Delphi accepts any of the Utf8 spaces for separating
> identifiers.
> https://www.compart.com/en/unicode/category/Zs
> and https://en.wikipedia.org/wiki/Word_divider
> Especially the zero width space
>
> And the soft hyphen? Will it be ignored, so the same identifier in
> different locations of the source can have it, or not have it?
> https://en.wikipedia.org/wiki/Soft_hyphen


It could very well be that Delphi (and other languages) follows the Unicode
Standard Annex #31 which is about Unicode Identifiers in programming
languages and also deals with case insensitive identifiers (
https://unicode.org/reports/tr31/ ).

Regards,
Sven
-- 
___
lazarus mailing list
lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Proposal: Allow Umlaute and Accented Characters in Identifiers

2020-07-03 Thread Martin Frb via lazarus

On 03/07/2020 16:37, Michael Van Canneyt via lazarus wrote:



On Fri, 3 Jul 2020, Martin Frb via lazarus wrote:


On 03/07/2020 16:21, Péter Gábor via lazarus wrote:

Hi!

I hope that you did not misread my words/sentences.
Your example if perfect to illustrate the reason why I don't want
international characters in the language itself (and identifiers).

Yes, that was my understanding.

You gave reasons why it would be a bad idea. I added a reason, that I 
think would make the idea even worse.

In other words, I supported the current a-z0-1_ set.


I did a quick test in Delphi:


[dcc32 Error] doti.dpr(9): E2003 Undeclared identifier: 'ß'

So indeed, case-insensitivity is lost. Even in German.


And that, despite the German ß is not locale dependent. It has exactly 
one uppercase version.

Were as "i" has 2. (But not within any one locale)

I would guess that if you copy and paste, and some of your umlauts/chars 
are composed, some decomposed, that will likely not work either.
And for composed chars with more than one combining codepoint, if the 
order of the combining codepoints does not matter, the problem will 
likely be the same.


Then there are full width codepoint for some chars. (They could be 
argued to be ignored, but readability would be gone...)

https://en.wikipedia.org/wiki/Halfwidth_and_Fullwidth_Forms_(Unicode_block)
So "A" and "A" should also be the same.
And full width digits should be allowed in numbers.

I do wonder, if Delphi accepts any of the Utf8 spaces for separating 
identifiers.

https://www.compart.com/en/unicode/category/Zs
and https://en.wikipedia.org/wiki/Word_divider
Especially the zero width space

And the soft hyphen? Will it be ignored, so the same identifier in 
different locations of the source can have it, or not have it?

https://en.wikipedia.org/wiki/Soft_hyphen

and many more.
--
___
lazarus mailing list
lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Proposal: Allow Umlaute and Accented Characters in Identifiers

2020-07-03 Thread R.Smith via lazarus

Michael:


I did a quick test in Delphi:

program doti;

{$APPTYPE CONSOLE}


...

Great job - Thanks. That came in as I was contemplating doing the same test.

I wonder how this test will go in Python - I suppose it cannot matter 
for case-sensitive languages.




--
___
lazarus mailing list
lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Proposal: Allow Umlaute and Accented Characters in Identifiers

2020-07-03 Thread Michael Van Canneyt via lazarus



On Fri, 3 Jul 2020, Martin Frb via lazarus wrote:


On 03/07/2020 16:21, Péter Gábor via lazarus wrote:

Hi!

I hope that you did not misread my words/sentences.
Your example if perfect to illustrate the reason why I don't want
international characters in the language itself (and identifiers).

Yes, that was my understanding.

You gave reasons why it would be a bad idea. I added a reason, that I 
think would make the idea even worse.

In other words, I supported the current a-z0-1_ set.


I did a quick test in Delphi:

program doti;

{$APPTYPE CONSOLE}

Var
  i: Integer; // lowercase dotted i in turkish

begin
  for İ :=0 to 10 do // uppercase dotted I in turkish
writeln(i);
end.

Results in

[dcc32 Error] doti.dpr(9): E2003 Undeclared identifier: 'İ'

Same for German:

program doti;

{$APPTYPE CONSOLE}

Var
  ẞ: Integer;

begin
  for ß :=0 to 10 do
writeln(ß);
end.

[dcc32 Error] doti.dpr(9): E2003 Undeclared identifier: 'ß'

So indeed, case-insensitivity is lost. Even in German.

Michael.-- 
___
lazarus mailing list
lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Proposal: Allow Umlaute and Accented Characters in Identifiers

2020-07-03 Thread Martin Frb via lazarus

On 03/07/2020 16:21, Péter Gábor via lazarus wrote:

Hi!

I hope that you did not misread my words/sentences.
Your example if perfect to illustrate the reason why I don't want
international characters in the language itself (and identifiers).

Yes, that was my understanding.

You gave reasons why it would be a bad idea. I added a reason, that I 
think would make the idea even worse.

In other words, I supported the current a-z0-1_ set.

--
___
lazarus mailing list
lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Proposal: Allow Umlaute and Accented Characters in Identifiers

2020-07-03 Thread Péter Gábor via lazarus
Hi!

I hope that you did not misread my words/sentences.
Your example if perfect to illustrate the reason why I don't want
international characters in the language itself (and identifiers).


2020. 07. 03. 16:13 keltezéssel, Martin Frb via lazarus írta:
> On 03/07/2020 14:55, Péter Gábor via lazarus wrote:
>> Hi!
>>
>> Then you must allow Cyrillic,d Arabic and so Chinese and other national
>> and special characters to be used in identifiers.
> Worse, the same source may then compile or fail to compile depending
> on the locale.
>
> Pascal is case insensitive.
> var I: integer; // upper i
> ...
> for i := 0 to x do ...;
>
> compiles today.
>
> But when compiling, using Turkish locale, this would fail.
> In Turkish there is a dotted and a dotless i, both upper and lower.
> So I and i are different letters.
> https://en.wikipedia.org/wiki/Dotted_and_dotless_I
>

-- 
Péter Gábor
p...@freemail.hu

-- 
___
lazarus mailing list
lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Proposal: Allow Umlaute and Accented Characters in Identifiers

2020-07-03 Thread Martin Frb via lazarus

On 03/07/2020 14:55, Péter Gábor via lazarus wrote:

Hi!

Then you must allow Cyrillic,d Arabic and so Chinese and other national
and special characters to be used in identifiers.
Worse, the same source may then compile or fail to compile depending on 
the locale.


Pascal is case insensitive.
var I: integer; // upper i
...
for i := 0 to x do ...;

compiles today.

But when compiling, using Turkish locale, this would fail.
In Turkish there is a dotted and a dotless i, both upper and lower.
So I and i are different letters.
https://en.wikipedia.org/wiki/Dotted_and_dotless_I

--
___
lazarus mailing list
lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Proposal: Allow Umlaute and Accented Characters in Identifiers

2020-07-03 Thread Special via lazarus

Am 03.07.2020 um 14:55 schrieb Péter Gábor via lazarus:

Hi!

Then you must allow Cyrillic,d Arabic and so Chinese and other national
and special characters to be used in identifiers.
There was a thread about this issue on the list (or maybe on fpc's one)
and (as I can remember) the conclusion was that it's a bad idea.
To keep source codes universally readable and understandable the special
and national characters must be avoided in the language itself (and so
in identifiers).


2020. 07. 03. 14:09 keltezéssel, Special via lazarus írta:

Hi,

we have many Delphi programs with identifiers containing parts like
'Köln' and 'Liège'. These programs we want to convert to Lazarus.
Unfortunately, Lazarus (or FP) seems not to be able to use identifiers
with umlaute and accents. Maybe the reason for this could be pure
historical and stem from the pre Unicode epoche.

Manually chanching all those identifiers and modifying the references
to them is not very elegant. By the way: Using the international names
The international name of 'München', for instance, is 'Monaco', the
same name as that for the Grimaldi Imperium.

Circumscribing is also no option. The name of Müllerstadt is
'Müllerstadt' and not 'Muellerstadt'.

Could Lazarus (and/or maybe Free Pascal) be improved to tolerate those
identfiers?

Regards  --  Joe


Hi, Peter,

on a Elementary  School near Heidelberg the nine-years-old pupils learn 
programming with Delphi 10.3 Community Edition. In one of the programs 
they use 'Type ZimmerType = (Küche, Wohnzimmer, Schlafzimmer);",  
translated something like  "Type RoomType = (Kitchen, LeavingRoon, 
BedRoom)".  Their English skills are poor, they don't yet know the 
meaning of 'Kitchen'. So their teacher was happy to be able to use "Küche".


As we see, Pascal is not only a programming language for professionals 
with the need for code universally (and internationally) readable, but 
also for kids on elementary schools. Why should it be forbidden for them 
to use "Küche"?  No one is forced to use identifiers with umlaute and  
accents, if Lazarus would allow that, if he wishes to write 
internationally readable code.


I think, it should be the decision of the programmer, to write 
internationally or nationally better understandable code. He should not 
be forced to avoid "Köln" and "Liège", as Lazarus does.


By the way, Python 3 (actually a programmimng language with very much 
more users than Pascal in all its flavours) deliberately allows "Liège".


Regards --  Joe
--
___
lazarus mailing list
lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus


Re: [Lazarus] Proposal: Allow Umlaute and Accented Characters in Identifiers

2020-07-03 Thread Péter Gábor via lazarus
Hi!

Then you must allow Cyrillic,d Arabic and so Chinese and other national
and special characters to be used in identifiers.
There was a thread about this issue on the list (or maybe on fpc's one)
and (as I can remember) the conclusion was that it's a bad idea.
To keep source codes universally readable and understandable the special
and national characters must be avoided in the language itself (and so
in identifiers).


2020. 07. 03. 14:09 keltezéssel, Special via lazarus írta:
> Hi,
>
> we have many Delphi programs with identifiers containing parts like
> 'Köln' and 'Liège'. These programs we want to convert to Lazarus.
> Unfortunately, Lazarus (or FP) seems not to be able to use identifiers
> with umlaute and accents. Maybe the reason for this could be pure
> historical and stem from the pre Unicode epoche.
>
> Manually chanching all those identifiers and modifying the references
> to them is not very elegant. By the way: Using the international names
> of cities instead of their orginal names introduces new difficulties.
> The international name of 'München', for instance, is 'Monaco', the
> same name as that for the Grimaldi Imperium.
>
> Circumscribing is also no option. The name of Müllerstadt is
> 'Müllerstadt' and not 'Muellerstadt'.
>
> Could Lazarus (and/or maybe Free Pascal) be improved to tolerate those
> identfiers?
>
> Regards  --  Joe

-- 
Péter Gábor
p...@freemail.hu


-- 
___
lazarus mailing list
lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus