Julia programming language: Difference between revisions

From annawiki
No edit summary
No edit summary
Line 17: Line 17:


https://docs.julialang.org/en/stable/manual/variables/#Allowed-Variable-Names-1
https://docs.julialang.org/en/stable/manual/variables/#Allowed-Variable-Names-1
*must begin with a letter (A-Z or a-z), underscore, or a subset of Unicode code points greater than 00A0; in particular, Unicode character categories Lu/Ll/Lt/Lm/Lo/Nl (letters), Sc/So (currency and other symbols), and a few other letter-like characters (e.g. a subset of the Sm math symbols) are allowed.  
*must begin with a letter (A-Z or a-z), underscore, or a subset of Unicode code points greater than 00A0; in particular, Unicode character categories Lu/Ll/Lt/Lm/Lo/Nl (letters), Sc/So (currency and other symbols), and a few other letter-like characters (e.g. a subset of the Sm math symbols) are allowed. (WHICH?)
*Subsequent characters may also include ! and digits (0-9 and other characters in categories Nd/No), as well as other Unicode code points: diacritics and other modifying marks (categories Mn/Mc/Me/Sk), some punctuation connectors (category Pc), primes, and a few other characters.
*Subsequent characters may also include ! and digits (0-9 and other characters in categories Nd/No), as well as other Unicode code points: diacritics and other modifying marks (categories Mn/Mc/Me/Sk), some punctuation connectors (category Pc), primes, and a few other characters.

Revision as of 2018-08-14T16:09:32

https://docs.julialang.org/en/stable/manual/strings/

  • Input of Unicode character in single quotes
    • \u followed by up to four hexadecimal digits or
    • \U followed by up to eight hexadecimal digits


Cc: Other, control
Cn: Other, not assigned
In: Invalid, too high
Ll: Letter, lowercase
Lu: Letter, uppercase
Ma: Malformed, bad data
Po: Punctuation, other
Sm: Symbol, math
Zs: Separator, space

Not in the doc: the classes are from https://www.unicode.org/versions/Unicode11.0.0/ch04.pdf#G134153

https://docs.julialang.org/en/stable/manual/variables/#Allowed-Variable-Names-1

  • must begin with a letter (A-Z or a-z), underscore, or a subset of Unicode code points greater than 00A0; in particular, Unicode character categories Lu/Ll/Lt/Lm/Lo/Nl (letters), Sc/So (currency and other symbols), and a few other letter-like characters (e.g. a subset of the Sm math symbols) are allowed. (WHICH?)
  • Subsequent characters may also include ! and digits (0-9 and other characters in categories Nd/No), as well as other Unicode code points: diacritics and other modifying marks (categories Mn/Mc/Me/Sk), some punctuation connectors (category Pc), primes, and a few other characters.