Repository navigation
Conversation
During discussion about using the new unstable `char::is_xid_start` and `char::is_xid_continue` in the compiler, a point was made that doing so would mean that the Unicode version used to validate identifiers would become tied to whatever std supports. However, we are already using std's version of Unicode in many other places, e.g. via `char::is_whitespace`, so this actually seems reasonable to codify. Thus, add lanugage indicating that the exact Unicode version is delegated to the standard library. This effectively means that T-lang does not need to FCP future Unicode updates either. As also noted on the XID thread, Java provides us some prior art here <https://docs.oracle.com/javase/specs/jls/se23/html/jls-3.html#jls-3.1>.
3b1c0eb to
c95c4dc
Compare
That statement seems a bit too vague & misleading. We're in fact not using (I did just find out that we seem to be using |
|
Hm, I thought that at least https://github.com/rust-lang/rust/blob/4c46afa63688fb473618f9b3553d70b0c15a88eb/compiler/rustc_span/src/source_map.rs#L666 was load-bearing in some ways but perhaps not. I think this is still worth it regardless, rather than managing two versions separately or pinning a version, but I'll update the motivation. |
|
|
During discussion about using the new unstable
char::is_xid_startandchar::is_xid_continuein the compiler, a point was made that doing sowould mean that the Unicode version used to validate identifiers would
become tied to whatever std supports. However, we are already using
std's version of Unicode in many other places, e.g. via
char::is_whitespace, so this actually seems reasonable to codify.Thus, add lanugage indicating that the exact Unicode version is
delegated to the standard library. This effectively means that T-lang
does not need to FCP future Unicode updates either.
As also noted on the XID thread, Java provides us some prior art here
https://docs.oracle.com/javase/specs/jls/se23/html/jls-3.html#jls-3.1.
XID discussion: rust-lang/rust#164841