File tree Expand file tree Collapse file tree 2 files changed +13
-2
lines changed Expand file tree Collapse file tree 2 files changed +13
-2
lines changed Original file line number Diff line number Diff line change @@ -1217,6 +1217,18 @@ list of substrings of `STR' each followed by its face."
1217
1217
" let" font-lock-keyword-face
1218
1218
" '\\\\ '" font-lock-string-face )))
1219
1219
1220
+ (ert-deftest font-lock-hex-escape-character-literal ()
1221
+ (rust-test-font-lock
1222
+ " let ch = '\\ x1f';"
1223
+ '(" let" font-lock-keyword-face
1224
+ " '\\ x1f'" font-lock-string-face )))
1225
+
1226
+ (ert-deftest font-lock-unicode-escape-character-literal ()
1227
+ (rust-test-font-lock
1228
+ " let ch = '\\ u{1ffff}';"
1229
+ '(" let" font-lock-keyword-face
1230
+ " '\\ u{1ffff}'" font-lock-string-face )))
1231
+
1220
1232
(ert-deftest font-lock-raw-strings-no-hashes ()
1221
1233
(rust-test-font-lock
1222
1234
" r\" No hashes\" ;"
Original file line number Diff line number Diff line change 83
83
(seq
84
84
" \\ "
85
85
(or
86
- (: " U" (= 8 xdigit))
87
- (: " u" (= 4 xdigit))
86
+ (: " u{" (** 1 6 xdigit) " }" )
88
87
(: " x" (= 2 xdigit))
89
88
(any " 'nrt0\" \\ " )))
90
89
(not (any " '\\ " ))
You can’t perform that action at this time.
0 commit comments