Commit Graph

4 Commits

Author SHA1 Message Date
Stephen Heumann
ead95bcb12 Implement C23 changes to universal character names.
As of C23, UCNs within string literals or character constants can contain any valid Unicode code point, including ASCII characters or control characters.

The validity of UCNs within identifiers is now defined based on the XID_Start and XID_Continue Unicode properties. A helper program is used to generate tables of the allowed characters based on a Unicode data file. These can be updated for future Unicode versions by re-running the helper program using the updated Unicode data files.
2024-09-13 22:14:43 -05:00
Stephen Heumann
5871820e0c Support UTF-8/16/32 string literals and character constants (C11).
These have u8, u, or U prefixes, respectively. The types char16_t and char32_t (defined in <uchar.h>) are used for UTF-16 and UTF-32 code points.
2021-10-11 20:54:37 -05:00
Stephen Heumann
656868a095 Implement support for universal character names in identifiers. 2020-01-20 17:22:06 -06:00
Stephen Heumann
d24dacf01a Add initial support for universal character names.
This currently only works in character constants or strings, not identifiers.
2020-01-19 23:59:54 -06:00