Commit 92b1d9c
committed
fix(scanner): the identity refusal quotes what was read, not what was recorded
The tokeniser stops at the first character it does not accept, so a declaration
it cannot read at all yields an EMPTY name -- and `'' is not a module name`
names nothing the author can find. Measured on a non-ASCII name, where
`is_module_name_char` tests bytes with std::isalnum and every byte of a UTF-8
sequence is false: the message read `''` where the source said `模块`.
GCC 16.1 refuses that declaration too (`unrecognized 'MODULE-EXPORT ...'`), so
this is a clearer sentence for a refusal that already existed rather than a new
restriction. The message now also states what a name is.1 parent 0b283ac commit 92b1d9c
2 files changed
Lines changed: 38 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
827 | 827 | | |
828 | 828 | | |
829 | 829 | | |
| 830 | + | |
| 831 | + | |
| 832 | + | |
| 833 | + | |
| 834 | + | |
| 835 | + | |
| 836 | + | |
| 837 | + | |
| 838 | + | |
| 839 | + | |
| 840 | + | |
830 | 841 | | |
831 | 842 | | |
832 | 843 | | |
833 | 844 | | |
834 | | - | |
| 845 | + | |
| 846 | + | |
| 847 | + | |
835 | 848 | | |
836 | 849 | | |
837 | 850 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1102 | 1102 | | |
1103 | 1103 | | |
1104 | 1104 | | |
| 1105 | + | |
| 1106 | + | |
| 1107 | + | |
| 1108 | + | |
| 1109 | + | |
| 1110 | + | |
| 1111 | + | |
| 1112 | + | |
| 1113 | + | |
| 1114 | + | |
| 1115 | + | |
| 1116 | + | |
| 1117 | + | |
| 1118 | + | |
| 1119 | + | |
| 1120 | + | |
| 1121 | + | |
| 1122 | + | |
| 1123 | + | |
| 1124 | + | |
| 1125 | + | |
| 1126 | + | |
| 1127 | + | |
| 1128 | + | |
1105 | 1129 | | |
1106 | 1130 | | |
1107 | 1131 | | |
| |||
0 commit comments