-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
case-sensitivity for syntax #8
Comments
In principle I'm okay with this, but I have concerns about locale handling such as the Turkish |
Okay, after my latest round of getting my hands dirty with Unicode for whatever reason, I'd suggest the following: Two identifiers are considered equivalent if they have the same sequence of codepoints under the NFKC_CaseFold transformation. This does Compatibility Decomposition, which breaks apart precomposed characters, and does things like change superscripts into regular numbers, etc., followed by Canonical Composition. Then it applies Unicode casefolding, which generally maps uppercase to lowercase, except where it doesn't, in such a way as to make case-insensitive comparisons as tractable as possible. However, because people going around defining a variable as If a symbol is shadowed (by NFKC_CaseFold-equivalence), but the shadowing symbol's identifier is not NFC-equivalent to the shadowed symbol's identifier, and the shadowing symbol is accessed using an identifier which is NFC-equivalent to the shadowed symbol's identifier, then a warning is emitted, rather than a lint. A clarifying example: if you define a global See http://unicode.org/reports/tr15/ to learn about NFC, NFD, NFKC, and NFKD; it's fairly readable. This would allow a case-insensitive C64 implementation to be compatible with source files which were restricted to PETSCII-mappable characters, while allowing users of the cross-compiler to name things in whatever language they felt like. |
that is really well-thought out and well-researched. 👍 |
So, this is a little bit of a weird suggestion. What if we make our language case-insensitive outside of string literals?
I do have a pipe dream of porting to the Commodore, and you know the Commodore is weird about case. Plus the shift key is physically difficult to press in combination with other keys when you're trying to type at any kind of speed.
The text was updated successfully, but these errors were encountered: