Skip to content

Commit 90b8d34

Browse files
committed
bump smallvec to 1.0
1 parent ab6e478 commit 90b8d34

File tree

19 files changed

+53
-47
lines changed

19 files changed

+53
-47
lines changed

Cargo.lock

+31-25
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ name = "arena"
6868
version = "0.0.0"
6969
dependencies = [
7070
"rustc_data_structures",
71-
"smallvec",
71+
"smallvec 1.0.0",
7272
]
7373

7474
[[package]]
@@ -486,7 +486,7 @@ dependencies = [
486486
"regex-syntax",
487487
"semver",
488488
"serde",
489-
"smallvec",
489+
"smallvec 0.6.10",
490490
"toml",
491491
"unicode-normalization",
492492
"url 2.1.0",
@@ -654,7 +654,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
654654
checksum = "0f0ed1a4de2235cabda8558ff5840bffb97fcb64c97827f354a451307df5f72b"
655655
dependencies = [
656656
"crossbeam-utils 0.6.5",
657-
"smallvec",
657+
"smallvec 0.6.10",
658658
]
659659

660660
[[package]]
@@ -2391,7 +2391,7 @@ dependencies = [
23912391
"libc",
23922392
"rand 0.6.1",
23932393
"rustc_version",
2394-
"smallvec",
2394+
"smallvec 0.6.10",
23952395
"winapi 0.3.6",
23962396
]
23972397

@@ -2406,7 +2406,7 @@ dependencies = [
24062406
"libc",
24072407
"redox_syscall",
24082408
"rustc_version",
2409-
"smallvec",
2409+
"smallvec 0.6.10",
24102410
"winapi 0.3.6",
24112411
]
24122412

@@ -3134,7 +3134,7 @@ dependencies = [
31343134
"rustc_target",
31353135
"scoped-tls",
31363136
"serialize",
3137-
"smallvec",
3137+
"smallvec 1.0.0",
31383138
"syntax",
31393139
"syntax_pos",
31403140
]
@@ -3146,7 +3146,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
31463146
checksum = "a623fd4805842e9bd0bb6e6dace63efede0ee22de4522a0b03b7c3d15a22f009"
31473147
dependencies = [
31483148
"rustc-ap-rustc_data_structures",
3149-
"smallvec",
3149+
"smallvec 0.6.10",
31503150
]
31513151

31523152
[[package]]
@@ -3175,7 +3175,7 @@ dependencies = [
31753175
"rustc-hash",
31763176
"rustc-rayon 0.2.0",
31773177
"rustc-rayon-core 0.2.0",
3178-
"smallvec",
3178+
"smallvec 0.6.10",
31793179
"stable_deref_trait",
31803180
]
31813181

@@ -3203,7 +3203,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
32033203
checksum = "457a5c204ae2fdaa5bdb5b196e58ca59896870d80445fe423063c9453496e3ea"
32043204
dependencies = [
32053205
"rustc-ap-serialize",
3206-
"smallvec",
3206+
"smallvec 0.6.10",
32073207
]
32083208

32093209
[[package]]
@@ -3249,7 +3249,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
32493249
checksum = "92679240e86f4583cc05f8dcf6439bdab87bac9e6555718469176de9bd52ba20"
32503250
dependencies = [
32513251
"indexmap",
3252-
"smallvec",
3252+
"smallvec 0.6.10",
32533253
]
32543254

32553255
[[package]]
@@ -3269,7 +3269,7 @@ dependencies = [
32693269
"rustc-ap-serialize",
32703270
"rustc-ap-syntax_pos",
32713271
"scoped-tls",
3272-
"smallvec",
3272+
"smallvec 0.6.10",
32733273
]
32743274

32753275
[[package]]
@@ -3392,7 +3392,7 @@ dependencies = [
33923392
"crossbeam-utils 0.6.5",
33933393
"serde",
33943394
"serde_json",
3395-
"smallvec",
3395+
"smallvec 0.6.10",
33963396
"syn 0.15.35",
33973397
"url 2.1.0",
33983398
"winapi 0.3.6",
@@ -3403,7 +3403,7 @@ name = "rustc_apfloat"
34033403
version = "0.0.0"
34043404
dependencies = [
34053405
"bitflags",
3406-
"smallvec",
3406+
"smallvec 1.0.0",
34073407
]
34083408

34093409
[[package]]
@@ -3483,7 +3483,7 @@ dependencies = [
34833483
"rustc-rayon-core 0.3.0",
34843484
"rustc_index",
34853485
"serialize",
3486-
"smallvec",
3486+
"smallvec 1.0.0",
34873487
"stable_deref_trait",
34883488
]
34893489

@@ -3551,7 +3551,7 @@ name = "rustc_index"
35513551
version = "0.0.0"
35523552
dependencies = [
35533553
"serialize",
3554-
"smallvec",
3554+
"smallvec 1.0.0",
35553555
]
35563556

35573557
[[package]]
@@ -3578,7 +3578,7 @@ dependencies = [
35783578
"rustc_traits",
35793579
"rustc_typeck",
35803580
"serialize",
3581-
"smallvec",
3581+
"smallvec 1.0.0",
35823582
"syntax",
35833583
"syntax_expand",
35843584
"syntax_ext",
@@ -3649,7 +3649,7 @@ dependencies = [
36493649
"rustc_index",
36503650
"rustc_target",
36513651
"serialize",
3652-
"smallvec",
3652+
"smallvec 1.0.0",
36533653
"stable_deref_trait",
36543654
"syntax",
36553655
"syntax_expand",
@@ -3674,7 +3674,7 @@ dependencies = [
36743674
"rustc_lexer",
36753675
"rustc_target",
36763676
"serialize",
3677-
"smallvec",
3677+
"smallvec 1.0.0",
36783678
"syntax",
36793679
"syntax_pos",
36803680
]
@@ -3745,7 +3745,7 @@ dependencies = [
37453745
"rustc_data_structures",
37463746
"rustc_errors",
37473747
"rustc_metadata",
3748-
"smallvec",
3748+
"smallvec 1.0.0",
37493749
"syntax",
37503750
"syntax_expand",
37513751
"syntax_pos",
@@ -3798,7 +3798,7 @@ dependencies = [
37983798
"rustc",
37993799
"rustc_data_structures",
38003800
"rustc_target",
3801-
"smallvec",
3801+
"smallvec 1.0.0",
38023802
"syntax",
38033803
"syntax_pos",
38043804
]
@@ -3825,7 +3825,7 @@ dependencies = [
38253825
"rustc_errors",
38263826
"rustc_index",
38273827
"rustc_target",
3828-
"smallvec",
3828+
"smallvec 1.0.0",
38293829
"syntax",
38303830
"syntax_pos",
38313831
]
@@ -4069,7 +4069,7 @@ name = "serialize"
40694069
version = "0.0.0"
40704070
dependencies = [
40714071
"indexmap",
4072-
"smallvec",
4072+
"smallvec 1.0.0",
40734073
]
40744074

40754075
[[package]]
@@ -4133,6 +4133,12 @@ version = "0.6.10"
41334133
source = "registry+https://github.com/rust-lang/crates.io-index"
41344134
checksum = "ab606a9c5e214920bb66c458cd7be8ef094f813f20fe77a54cc7dbfff220d4b7"
41354135

4136+
[[package]]
4137+
name = "smallvec"
4138+
version = "1.0.0"
4139+
source = "registry+https://github.com/rust-lang/crates.io-index"
4140+
checksum = "4ecf3b85f68e8abaa7555aa5abdb1153079387e60b718283d732f03897fcfc86"
4141+
41364142
[[package]]
41374143
name = "socket2"
41384144
version = "0.3.8"
@@ -4358,7 +4364,7 @@ dependencies = [
43584364
"rustc_target",
43594365
"scoped-tls",
43604366
"serialize",
4361-
"smallvec",
4367+
"smallvec 1.0.0",
43624368
"syntax_pos",
43634369
]
43644370

@@ -4376,7 +4382,7 @@ dependencies = [
43764382
"rustc_target",
43774383
"scoped-tls",
43784384
"serialize",
4379-
"smallvec",
4385+
"smallvec 1.0.0",
43804386
"syntax",
43814387
"syntax_pos",
43824388
]
@@ -4390,7 +4396,7 @@ dependencies = [
43904396
"rustc_data_structures",
43914397
"rustc_errors",
43924398
"rustc_target",
4393-
"smallvec",
4399+
"smallvec 1.0.0",
43944400
"syntax",
43954401
"syntax_expand",
43964402
"syntax_pos",

src/libarena/Cargo.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,4 +10,4 @@ path = "lib.rs"
1010

1111
[dependencies]
1212
rustc_data_structures = { path = "../librustc_data_structures" }
13-
smallvec = { version = "0.6.7", features = ["union", "may_dangle"] }
13+
smallvec = { version = "1.0", features = ["union", "may_dangle"] }

src/librustc/Cargo.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -39,5 +39,5 @@ parking_lot = "0.9"
3939
byteorder = { version = "1.3" }
4040
chalk-engine = { version = "0.9.0", default-features=false }
4141
rustc_fs_util = { path = "../librustc_fs_util" }
42-
smallvec = { version = "0.6.8", features = ["union", "may_dangle"] }
42+
smallvec = { version = "1.0", features = ["union", "may_dangle"] }
4343
measureme = "0.4"

src/librustc/arena.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -304,7 +304,7 @@ impl DropArena {
304304
// Move the content to the arena by copying it and then forgetting
305305
// the content of the SmallVec
306306
vec.as_ptr().copy_to_nonoverlapping(start_ptr, len);
307-
mem::forget(vec.drain());
307+
mem::forget(vec.drain(..));
308308

309309
// Record the destructors after doing the allocation as that may panic
310310
// and would cause `object`'s destuctor to run twice if it was recorded before

src/librustc/ty/inhabitedness/def_id_forest.rs

+5-5
Original file line numberDiff line numberDiff line change
@@ -76,19 +76,19 @@ impl<'tcx> DefIdForest {
7676
break;
7777
}
7878

79-
for id in ret.root_ids.drain() {
79+
for id in ret.root_ids.drain(..) {
8080
if next_forest.contains(tcx, id) {
8181
next_ret.push(id);
8282
} else {
8383
old_ret.push(id);
8484
}
8585
}
86-
ret.root_ids.extend(old_ret.drain());
86+
ret.root_ids.extend(old_ret.drain(..));
8787

8888
next_ret.extend(next_forest.root_ids.into_iter().filter(|&id| ret.contains(tcx, id)));
8989

9090
mem::swap(&mut next_ret, &mut ret.root_ids);
91-
next_ret.drain();
91+
next_ret.drain(..);
9292
}
9393
ret
9494
}
@@ -101,7 +101,7 @@ impl<'tcx> DefIdForest {
101101
let mut ret = DefIdForest::empty();
102102
let mut next_ret = SmallVec::new();
103103
for next_forest in iter {
104-
next_ret.extend(ret.root_ids.drain().filter(|&id| !next_forest.contains(tcx, id)));
104+
next_ret.extend(ret.root_ids.drain(..).filter(|&id| !next_forest.contains(tcx, id)));
105105

106106
for id in next_forest.root_ids {
107107
if !next_ret.contains(&id) {
@@ -110,7 +110,7 @@ impl<'tcx> DefIdForest {
110110
}
111111

112112
mem::swap(&mut next_ret, &mut ret.root_ids);
113-
next_ret.drain();
113+
next_ret.drain(..);
114114
}
115115
ret
116116
}

src/librustc_apfloat/Cargo.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,4 +10,4 @@ path = "lib.rs"
1010

1111
[dependencies]
1212
bitflags = "1.2.1"
13-
smallvec = { version = "0.6.7", features = ["union", "may_dangle"] }
13+
smallvec = { version = "1.0", features = ["union", "may_dangle"] }

src/librustc_data_structures/Cargo.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ stable_deref_trait = "1.0.0"
2323
rayon = { version = "0.3.0", package = "rustc-rayon" }
2424
rayon-core = { version = "0.3.0", package = "rustc-rayon-core" }
2525
rustc-hash = "1.0.1"
26-
smallvec = { version = "0.6.7", features = ["union", "may_dangle"] }
26+
smallvec = { version = "1.0", features = ["union", "may_dangle"] }
2727
rustc_index = { path = "../librustc_index", package = "rustc_index" }
2828

2929
[dependencies.parking_lot]

src/librustc_index/Cargo.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,4 +11,4 @@ doctest = false
1111

1212
[dependencies]
1313
rustc_serialize = { path = "../libserialize", package = "serialize" }
14-
smallvec = { version = "0.6.7", features = ["union", "may_dangle"] }
14+
smallvec = { version = "1.0", features = ["union", "may_dangle"] }

src/librustc_interface/Cargo.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ doctest = false
1212
[dependencies]
1313
log = "0.4"
1414
rayon = { version = "0.3.0", package = "rustc-rayon" }
15-
smallvec = { version = "0.6.7", features = ["union", "may_dangle"] }
15+
smallvec = { version = "1.0", features = ["union", "may_dangle"] }
1616
syntax = { path = "../libsyntax" }
1717
syntax_ext = { path = "../libsyntax_ext" }
1818
syntax_expand = { path = "../libsyntax_expand" }

src/librustc_metadata/Cargo.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ doctest = false
1313
flate2 = "1.0"
1414
log = "0.4"
1515
memmap = "0.6"
16-
smallvec = { version = "0.6.7", features = ["union", "may_dangle"] }
16+
smallvec = { version = "1.0", features = ["union", "may_dangle"] }
1717
rustc = { path = "../librustc" }
1818
rustc_data_structures = { path = "../librustc_data_structures" }
1919
errors = { path = "../librustc_errors", package = "rustc_errors" }

src/librustc_mir/Cargo.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -26,4 +26,4 @@ rustc_serialize = { path = "../libserialize", package = "serialize" }
2626
syntax = { path = "../libsyntax" }
2727
syntax_pos = { path = "../libsyntax_pos" }
2828
rustc_apfloat = { path = "../librustc_apfloat" }
29-
smallvec = { version = "0.6.7", features = ["union", "may_dangle"] }
29+
smallvec = { version = "1.0", features = ["union", "may_dangle"] }

src/librustc_resolve/Cargo.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -21,4 +21,4 @@ errors = { path = "../librustc_errors", package = "rustc_errors" }
2121
syntax_pos = { path = "../libsyntax_pos" }
2222
rustc_data_structures = { path = "../librustc_data_structures" }
2323
rustc_metadata = { path = "../librustc_metadata" }
24-
smallvec = { version = "0.6.7", features = ["union", "may_dangle"] }
24+
smallvec = { version = "1.0", features = ["union", "may_dangle"] }

src/librustc_traits/Cargo.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,4 +16,4 @@ rustc_target = { path = "../librustc_target" }
1616
syntax = { path = "../libsyntax" }
1717
syntax_pos = { path = "../libsyntax_pos" }
1818
chalk-engine = { version = "0.9.0", default-features=false }
19-
smallvec = { version = "0.6.7", features = ["union", "may_dangle"] }
19+
smallvec = { version = "1.0", features = ["union", "may_dangle"] }

src/librustc_typeck/Cargo.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ rustc = { path = "../librustc" }
1717
rustc_data_structures = { path = "../librustc_data_structures" }
1818
errors = { path = "../librustc_errors", package = "rustc_errors" }
1919
rustc_target = { path = "../librustc_target" }
20-
smallvec = { version = "0.6.7", features = ["union", "may_dangle"] }
20+
smallvec = { version = "1.0", features = ["union", "may_dangle"] }
2121
syntax = { path = "../libsyntax" }
2222
syntax_pos = { path = "../libsyntax_pos" }
2323
rustc_index = { path = "../librustc_index" }

src/libserialize/Cargo.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,4 +10,4 @@ path = "lib.rs"
1010

1111
[dependencies]
1212
indexmap = "1"
13-
smallvec = { version = "0.6.7", features = ["union", "may_dangle"] }
13+
smallvec = { version = "1.0", features = ["union", "may_dangle"] }

src/libsyntax/Cargo.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -21,4 +21,4 @@ rustc_data_structures = { path = "../librustc_data_structures" }
2121
rustc_index = { path = "../librustc_index" }
2222
rustc_lexer = { path = "../librustc_lexer" }
2323
rustc_target = { path = "../librustc_target" }
24-
smallvec = { version = "0.6.7", features = ["union", "may_dangle"] }
24+
smallvec = { version = "1.0", features = ["union", "may_dangle"] }

src/libsyntax/tokenstream.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -253,7 +253,7 @@ impl TokenStream {
253253

254254
// Get the first stream. If it's `None`, create an empty
255255
// stream.
256-
let mut iter = streams.drain();
256+
let mut iter = streams.drain(..);
257257
let mut first_stream_lrc = iter.next().unwrap().0;
258258

259259
// Append the elements to the first stream, after reserving

src/libsyntax_expand/Cargo.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -22,5 +22,5 @@ rustc_data_structures = { path = "../librustc_data_structures" }
2222
rustc_index = { path = "../librustc_index" }
2323
rustc_lexer = { path = "../librustc_lexer" }
2424
rustc_target = { path = "../librustc_target" }
25-
smallvec = { version = "0.6.7", features = ["union", "may_dangle"] }
25+
smallvec = { version = "1.0", features = ["union", "may_dangle"] }
2626
syntax = { path = "../libsyntax" }

0 commit comments

Comments
 (0)