Re: Can NFKC turn valid UAX 31 identifiers into non-identifiers?

From: Philippe Verdy via Unicode <unicode_at_unicode.org>
Date: Thu, 7 Jun 2018 12:05:20 +0200

In my opinion the usual constant is most often shown as "𝜋" (curly
serifs, slightly slanted) in mathematical articles and books (and in TeX),
but rarely as "π" (sans-serif).

There's a tradition of using handwriting for this symbol on backboards (not
always with serifs, but still often slanted). A notation with the "π"
symbol uses a legacy troundtrip mapping for old OEM charsets on
low-resolution text terminals where it was distinguished from the more
common Greek letter which was enhanced for better readability once old
low-resolution terminals were replaced. "π" looks too much like an Hangul
letter or a legacy box-drawing character and in fact difficult to recognize
as the pi constant, but it may still be found in some plain-text paragraphs
of inline mathematical formulas on screens (for programmers), at low
resolution or with small font sizes, where most text is in sans-serif Latin
and not slanted/italicized and not using an handwritten style.

If you think about writing a functional programming language using inline
formulas, then the "π" symbol may be ok for the constant, and custom
identifiers for a function would use standard Greek letters (or other
standard scripts for human languages), or would use "pi" in Latin. You
would then write "pi(π)" in that inline formula. For a classic 2D
mathematical layout, you would use "pi(𝜋)" with distinctive but
homonegeous styles for custom variables/function names and for the classic
mathematical constant.

As much as possible you will avoid mixing confusive letters/symbols in that
language.

Confusion is still possible is you use old texts mixing old Greek letters
for numerals: you would in that case avoid using the Greek letter pi for
naming your custom function, and would reserve the pi letter for the
wellknown constant. But applying distinctive styles will enhance your
formulas for readability.

2018-06-06 23:25 GMT+02:00 Hans Åberg via Unicode <unicode_at_unicode.org>:

>
> > On 4 Jun 2018, at 21:49, Manish Goregaokar via Unicode <
> unicode_at_unicode.org> wrote:
> >
> > The Rust community is considering adding non-ascii identifiers, which
> follow UAX #31 (XID_Start XID_Continue*, with tweaks). The proposal also
> asks for identifiers to be treated as equivalent under NFKC.
>
> So, in this language, if one defines a projection function 𝜋 and the
> usual constant π, what is 𝜋(π) supposed to mean? - Just curious.
>
>
>
>
Received on Thu Jun 07 2018 - 05:06:01 CDT

This archive was generated by hypermail 2.2.0 : Thu Jun 07 2018 - 05:06:03 CDT