File tree Expand file tree Collapse file tree 10 files changed +16
-16
lines changed Expand file tree Collapse file tree 10 files changed +16
-16
lines changed Original file line number Diff line number Diff line change @@ -3260,9 +3260,9 @@ checksum = "357703d41365b4b27c590e3ed91eabb1b663f07c4c084095e60cbed4362dff0d"
3260
3260
3261
3261
[[package ]]
3262
3262
name = " rustc-literal-escaper"
3263
- version = " 0.0.4 "
3263
+ version = " 0.0.5 "
3264
3264
source = " registry+https://github.com/rust-lang/crates.io-index"
3265
- checksum = " ab03008eb631b703dd16978282ae36c73282e7922fe101a4bd072a40ecea7b8b "
3265
+ checksum = " e4ee29da77c5a54f42697493cd4c9b9f31b74df666a6c04dfc4fde77abe0438b "
3266
3266
3267
3267
[[package ]]
3268
3268
name = " rustc-main"
Original file line number Diff line number Diff line change @@ -7,7 +7,7 @@ edition = "2024"
7
7
# tidy-alphabetical-start
8
8
bitflags = " 2.4.1"
9
9
memchr = " 2.7.4"
10
- rustc-literal-escaper = " 0.0.4 "
10
+ rustc-literal-escaper = " 0.0.5 "
11
11
rustc_ast_ir = { path = " ../rustc_ast_ir" }
12
12
rustc_data_structures = { path = " ../rustc_data_structures" }
13
13
rustc_index = { path = " ../rustc_index" }
Original file line number Diff line number Diff line change @@ -126,11 +126,11 @@ impl LitKind {
126
126
token:: CStr => {
127
127
let s = symbol. as_str ( ) ;
128
128
let mut buf = Vec :: with_capacity ( s. len ( ) ) ;
129
- unescape_c_str ( s, |_span, c | match c {
129
+ unescape_c_str ( s, |_span, res | match res {
130
130
Ok ( MixedUnit :: Char ( c) ) => {
131
- buf. extend_from_slice ( c. encode_utf8 ( & mut [ 0 ; 4 ] ) . as_bytes ( ) )
131
+ buf. extend_from_slice ( c. get ( ) . encode_utf8 ( & mut [ 0 ; 4 ] ) . as_bytes ( ) )
132
132
}
133
- Ok ( MixedUnit :: HighByte ( b) ) => buf. push ( b) ,
133
+ Ok ( MixedUnit :: HighByte ( b) ) => buf. push ( b. get ( ) ) ,
134
134
Err ( err) => {
135
135
assert ! ( !err. is_fatal( ) , "failed to unescape C string literal" )
136
136
}
Original file line number Diff line number Diff line change @@ -6,7 +6,7 @@ edition = "2024"
6
6
[dependencies ]
7
7
# tidy-alphabetical-start
8
8
bitflags = " 2.4.1"
9
- rustc-literal-escaper = " 0.0.4 "
9
+ rustc-literal-escaper = " 0.0.5 "
10
10
rustc_ast = { path = " ../rustc_ast" }
11
11
rustc_ast_pretty = { path = " ../rustc_ast_pretty" }
12
12
rustc_data_structures = { path = " ../rustc_data_structures" }
Original file line number Diff line number Diff line change @@ -5,7 +5,7 @@ edition = "2024"
5
5
6
6
[dependencies ]
7
7
# tidy-alphabetical-start
8
- rustc-literal-escaper = " 0.0.4 "
8
+ rustc-literal-escaper = " 0.0.5 "
9
9
rustc_lexer = { path = " ../rustc_lexer" }
10
10
# tidy-alphabetical-end
11
11
Original file line number Diff line number Diff line change @@ -15,7 +15,7 @@ test = false
15
15
doctest = false
16
16
17
17
[dependencies ]
18
- rustc-literal-escaper = " 0.0.4 "
18
+ rustc-literal-escaper = " 0.0.5 "
19
19
20
20
[features ]
21
21
rustc-dep-of-std = []
Original file line number Diff line number Diff line change @@ -271,9 +271,9 @@ dependencies = [
271
271
272
272
[[package ]]
273
273
name = " rustc-literal-escaper"
274
- version = " 0.0.4 "
274
+ version = " 0.0.5 "
275
275
source = " registry+https://github.com/rust-lang/crates.io-index"
276
- checksum = " ab03008eb631b703dd16978282ae36c73282e7922fe101a4bd072a40ecea7b8b "
276
+ checksum = " e4ee29da77c5a54f42697493cd4c9b9f31b74df666a6c04dfc4fde77abe0438b "
277
277
dependencies = [
278
278
" rustc-std-workspace-core" ,
279
279
" rustc-std-workspace-std" ,
Original file line number Diff line number Diff line change @@ -9,7 +9,7 @@ std = { path = "../std" }
9
9
# `core` when resolving doc links. Without this line a different `core` will be
10
10
# loaded from sysroot causing duplicate lang items and other similar errors.
11
11
core = { path = " ../core" }
12
- rustc-literal-escaper = { version = " 0.0.4 " , features = [" rustc-dep-of-std" ] }
12
+ rustc-literal-escaper = { version = " 0.0.5 " , features = [" rustc-dep-of-std" ] }
13
13
14
14
[features ]
15
15
default = [" rustc-dep-of-std" ]
Original file line number Diff line number Diff line change @@ -1471,11 +1471,11 @@ impl Literal {
1471
1471
let mut error = None ;
1472
1472
let mut buf = Vec :: with_capacity ( symbol. len ( ) ) ;
1473
1473
1474
- unescape_c_str ( symbol, |_span, c | match c {
1474
+ unescape_c_str ( symbol, |_span, res | match res {
1475
1475
Ok ( MixedUnit :: Char ( c) ) => {
1476
- buf. extend_from_slice ( c. encode_utf8 ( & mut [ 0 ; 4 ] ) . as_bytes ( ) )
1476
+ buf. extend_from_slice ( c. get ( ) . encode_utf8 ( & mut [ 0 ; 4 ] ) . as_bytes ( ) )
1477
1477
}
1478
- Ok ( MixedUnit :: HighByte ( b) ) => buf. push ( b) ,
1478
+ Ok ( MixedUnit :: HighByte ( b) ) => buf. push ( b. get ( ) ) ,
1479
1479
Err ( err) => {
1480
1480
if err. is_fatal ( ) {
1481
1481
error = Some ( ConversionErrorKind :: FailedToUnescape ( err) ) ;
Original file line number Diff line number Diff line change @@ -7,7 +7,7 @@ description = "A script to extract the lint documentation for the rustc book."
7
7
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
8
8
9
9
[dependencies ]
10
- rustc-literal-escaper = " 0.0.4 "
10
+ rustc-literal-escaper = " 0.0.5 "
11
11
serde_json = " 1.0.57"
12
12
tempfile = " 3.1.0"
13
13
walkdir = " 2.3.1"
You can’t perform that action at this time.
0 commit comments