Skip to content

Commit b45624a

Browse files
committed
Auto merge of #127696 - workingjubilee:rollup-5c951qn, r=workingjubilee
Rollup of 8 pull requests Successful merges: - #122300 (Add FileCheck annotations to mir-opt/dest-prop tests) - #126967 (Promote the `wasm32-wasip2` target to Tier 2) - #127370 (Windows: Add experimental support for linking std-required system DLLs using raw-dylib) - #127434 (use "bootstrap" instead of "rustbuild" in comments and docs) - #127477 (Clear `inner_attr_ranges` regularly.) - #127558 (More attribute cleanups) - #127659 (Use ManuallyDrop in BufWriter::into_parts) - #127677 (using correct tool mode for `run-make-support` crate) r? `@ghost` `@rustbot` modify labels: rollup
2 parents fcaa6fd + dc0c76f commit b45624a

File tree

54 files changed

+612
-297
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

54 files changed

+612
-297
lines changed

Cargo.lock

+154-3
Original file line numberDiff line numberDiff line change
@@ -1671,6 +1671,7 @@ dependencies = [
16711671
"compiler_builtins",
16721672
"rustc-std-workspace-alloc",
16731673
"rustc-std-workspace-core",
1674+
"serde",
16741675
]
16751676

16761677
[[package]]
@@ -1880,6 +1881,12 @@ dependencies = [
18801881
"syn 2.0.67",
18811882
]
18821883

1884+
[[package]]
1885+
name = "id-arena"
1886+
version = "2.2.1"
1887+
source = "registry+https://github.com/rust-lang/crates.io-index"
1888+
checksum = "25a2bc672d1148e28034f176e01fffebb08b35768468cc954630da77a1449005"
1889+
18831890
[[package]]
18841891
name = "ident_case"
18851892
version = "1.0.1"
@@ -2109,6 +2116,12 @@ version = "1.0.5"
21092116
source = "registry+https://github.com/rust-lang/crates.io-index"
21102117
checksum = "db13adb97ab515a3691f56e4dbab09283d0b86cb45abd991d8634a9d6f501760"
21112118

2119+
[[package]]
2120+
name = "lexopt"
2121+
version = "0.3.0"
2122+
source = "registry+https://github.com/rust-lang/crates.io-index"
2123+
checksum = "baff4b617f7df3d896f97fe922b64817f6cd9a756bb81d40f8883f2f66dcb401"
2124+
21122125
[[package]]
21132126
name = "libc"
21142127
version = "0.2.155"
@@ -2623,7 +2636,7 @@ dependencies = [
26232636
"indexmap",
26242637
"memchr",
26252638
"ruzstd 0.5.0",
2626-
"wasmparser",
2639+
"wasmparser 0.118.2",
26272640
]
26282641

26292642
[[package]]
@@ -3425,7 +3438,7 @@ dependencies = [
34253438
"object 0.34.0",
34263439
"regex",
34273440
"similar",
3428-
"wasmparser",
3441+
"wasmparser 0.118.2",
34293442
]
34303443

34313444
[[package]]
@@ -3812,7 +3825,7 @@ dependencies = [
38123825
"thin-vec",
38133826
"thorin-dwp",
38143827
"tracing",
3815-
"wasm-encoder",
3828+
"wasm-encoder 0.200.0",
38163829
"windows",
38173830
]
38183831

@@ -5256,6 +5269,15 @@ dependencies = [
52565269
"color-eyre",
52575270
]
52585271

5272+
[[package]]
5273+
name = "spdx"
5274+
version = "0.10.6"
5275+
source = "registry+https://github.com/rust-lang/crates.io-index"
5276+
checksum = "47317bbaf63785b53861e1ae2d11b80d6b624211d42cb20efcd210ee6f8a14bc"
5277+
dependencies = [
5278+
"smallvec",
5279+
]
5280+
52595281
[[package]]
52605282
name = "spdx-expression"
52615283
version = "0.5.2"
@@ -6304,6 +6326,28 @@ version = "0.2.92"
63046326
source = "registry+https://github.com/rust-lang/crates.io-index"
63056327
checksum = "af190c94f2773fdb3729c55b007a722abb5384da03bc0986df4c289bf5567e96"
63066328

6329+
[[package]]
6330+
name = "wasm-component-ld"
6331+
version = "0.5.4"
6332+
source = "registry+https://github.com/rust-lang/crates.io-index"
6333+
checksum = "314d932d5e84c9678751b85498b1482b2f32f185744e449d3ce0b1d400376dad"
6334+
dependencies = [
6335+
"anyhow",
6336+
"clap",
6337+
"lexopt",
6338+
"tempfile",
6339+
"wasmparser 0.210.0",
6340+
"wat",
6341+
"wit-component",
6342+
]
6343+
6344+
[[package]]
6345+
name = "wasm-component-ld-wrapper"
6346+
version = "0.1.0"
6347+
dependencies = [
6348+
"wasm-component-ld",
6349+
]
6350+
63076351
[[package]]
63086352
name = "wasm-encoder"
63096353
version = "0.200.0"
@@ -6313,6 +6357,40 @@ dependencies = [
63136357
"leb128",
63146358
]
63156359

6360+
[[package]]
6361+
name = "wasm-encoder"
6362+
version = "0.210.0"
6363+
source = "registry+https://github.com/rust-lang/crates.io-index"
6364+
checksum = "e7e3764d9d6edabd8c9e16195e177be0d20f6ab942ad18af52860f12f82bc59a"
6365+
dependencies = [
6366+
"leb128",
6367+
]
6368+
6369+
[[package]]
6370+
name = "wasm-encoder"
6371+
version = "0.211.1"
6372+
source = "registry+https://github.com/rust-lang/crates.io-index"
6373+
checksum = "5e7d931a1120ef357f32b74547646b6fa68ea25e377772b72874b131a9ed70d4"
6374+
dependencies = [
6375+
"leb128",
6376+
]
6377+
6378+
[[package]]
6379+
name = "wasm-metadata"
6380+
version = "0.210.0"
6381+
source = "registry+https://github.com/rust-lang/crates.io-index"
6382+
checksum = "012729d1294907fcb0866f08460ab95426a6d0b176a599619b84cac7653452b4"
6383+
dependencies = [
6384+
"anyhow",
6385+
"indexmap",
6386+
"serde",
6387+
"serde_derive",
6388+
"serde_json",
6389+
"spdx",
6390+
"wasm-encoder 0.210.0",
6391+
"wasmparser 0.210.0",
6392+
]
6393+
63166394
[[package]]
63176395
name = "wasmparser"
63186396
version = "0.118.2"
@@ -6323,6 +6401,42 @@ dependencies = [
63236401
"semver",
63246402
]
63256403

6404+
[[package]]
6405+
name = "wasmparser"
6406+
version = "0.210.0"
6407+
source = "registry+https://github.com/rust-lang/crates.io-index"
6408+
checksum = "a7bbcd21e7581619d9f6ca00f8c4f08f1cacfe58bf63f83af57cd0476f1026f5"
6409+
dependencies = [
6410+
"ahash",
6411+
"bitflags 2.5.0",
6412+
"hashbrown",
6413+
"indexmap",
6414+
"semver",
6415+
"serde",
6416+
]
6417+
6418+
[[package]]
6419+
name = "wast"
6420+
version = "211.0.1"
6421+
source = "registry+https://github.com/rust-lang/crates.io-index"
6422+
checksum = "b25506dd82d00da6b14a87436b3d52b1d264083fa79cdb72a0d1b04a8595ccaa"
6423+
dependencies = [
6424+
"bumpalo",
6425+
"leb128",
6426+
"memchr",
6427+
"unicode-width",
6428+
"wasm-encoder 0.211.1",
6429+
]
6430+
6431+
[[package]]
6432+
name = "wat"
6433+
version = "1.211.1"
6434+
source = "registry+https://github.com/rust-lang/crates.io-index"
6435+
checksum = "eb716ca6c86eecac2d82541ffc39860118fc0af9309c4f2670637bea2e1bdd7d"
6436+
dependencies = [
6437+
"wast",
6438+
]
6439+
63266440
[[package]]
63276441
name = "winapi"
63286442
version = "0.3.9"
@@ -6550,6 +6664,43 @@ dependencies = [
65506664
"memchr",
65516665
]
65526666

6667+
[[package]]
6668+
name = "wit-component"
6669+
version = "0.210.0"
6670+
source = "registry+https://github.com/rust-lang/crates.io-index"
6671+
checksum = "a450bdb5d032acf1fa0865451fa0c6f50e62f2d31eaa8dba967c2e2d068694a4"
6672+
dependencies = [
6673+
"anyhow",
6674+
"bitflags 2.5.0",
6675+
"indexmap",
6676+
"log",
6677+
"serde",
6678+
"serde_derive",
6679+
"serde_json",
6680+
"wasm-encoder 0.210.0",
6681+
"wasm-metadata",
6682+
"wasmparser 0.210.0",
6683+
"wit-parser",
6684+
]
6685+
6686+
[[package]]
6687+
name = "wit-parser"
6688+
version = "0.210.0"
6689+
source = "registry+https://github.com/rust-lang/crates.io-index"
6690+
checksum = "60a965cbd439af19a4b44a54a97ab8957d86f02d01320efc9e31c1d3605c6710"
6691+
dependencies = [
6692+
"anyhow",
6693+
"id-arena",
6694+
"indexmap",
6695+
"log",
6696+
"semver",
6697+
"serde",
6698+
"serde_derive",
6699+
"serde_json",
6700+
"unicode-xid",
6701+
"wasmparser 0.210.0",
6702+
]
6703+
65536704
[[package]]
65546705
name = "writeable"
65556706
version = "0.5.5"

Cargo.toml

+4
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,7 @@ members = [
4545
"src/tools/opt-dist",
4646
"src/tools/coverage-dump",
4747
"src/tools/rustc-perf-wrapper",
48+
"src/tools/wasm-component-ld",
4849
]
4950

5051
exclude = [
@@ -104,6 +105,9 @@ rustc-demangle.debug = 0
104105
[profile.release.package.lld-wrapper]
105106
debug = 0
106107
strip = true
108+
[profile.release.package.wasm-component-ld-wrapper]
109+
debug = 0
110+
strip = true
107111

108112
[patch.crates-io]
109113
# See comments in `library/rustc-std-workspace-core/README.md` for what's going on

INSTALL.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -215,7 +215,7 @@ python x.py build
215215

216216
Right now, building Rust only works with some known versions of Visual Studio.
217217
If you have a more recent version installed and the build system doesn't
218-
understand, you may need to force rustbuild to use an older version.
218+
understand, you may need to force bootstrap to use an older version.
219219
This can be done by manually calling the appropriate vcvars file before running
220220
the bootstrap.
221221

compiler/rustc_ast/src/attr/mod.rs

+10-13
Original file line numberDiff line numberDiff line change
@@ -202,21 +202,18 @@ impl Attribute {
202202
}
203203
}
204204

205-
// Named `get_tokens` to distinguish it from the `<Attribute as HasTokens>::tokens` method.
206-
pub fn get_tokens(&self) -> TokenStream {
207-
match &self.kind {
208-
AttrKind::Normal(normal) => TokenStream::new(
209-
normal
210-
.tokens
211-
.as_ref()
212-
.unwrap_or_else(|| panic!("attribute is missing tokens: {self:?}"))
213-
.to_attr_token_stream()
214-
.to_token_trees(),
215-
),
216-
&AttrKind::DocComment(comment_kind, data) => TokenStream::token_alone(
205+
pub fn token_trees(&self) -> Vec<TokenTree> {
206+
match self.kind {
207+
AttrKind::Normal(ref normal) => normal
208+
.tokens
209+
.as_ref()
210+
.unwrap_or_else(|| panic!("attribute is missing tokens: {self:?}"))
211+
.to_attr_token_stream()
212+
.to_token_trees(),
213+
AttrKind::DocComment(comment_kind, data) => vec![TokenTree::token_alone(
217214
token::DocComment(comment_kind, self.style, data),
218215
self.span,
219-
),
216+
)],
220217
}
221218
}
222219
}

0 commit comments

Comments
 (0)