Skip to content

Conversation

alexcrichton
Copy link
Member

This commit adds some documentation about the state of -Cpanic=unwind for the following wasm targets:

  • wasm32-unknown-unknown
  • wasm32-wasip1
  • wasm32-wasip2
  • wasm32v1-none

Notably it's possible to use -Cpanic=unwind with -Zbuild-std and it's also mentioned that there are no concrete proposals at this time to adding a new set of targets which support unwinding. My hunch is that in a few years' time it would make sense to enable it by default on these targets (except for wasm32v1-none) but that's a problem for future folks to debate. For now this is an attempt to document the status quo.

@rustbot
Copy link
Collaborator

rustbot commented Oct 3, 2025

Some changes occurred in src/doc/rustc/src/platform-support

cc @Noratrieb

@rustbot rustbot added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Oct 3, 2025
@rustbot
Copy link
Collaborator

rustbot commented Oct 3, 2025

r? @SparrowLii

rustbot has assigned @SparrowLii.
They will have a look at your PR within the next two weeks and either review your PR or reassign to another reviewer.

Use r? to explicitly pick a reviewer

@rust-log-analyzer

This comment has been minimized.

This commit adds some documentation about the state of `-Cpanic=unwind`
for the following wasm targets:

* `wasm32-unknown-unknown`
* `wasm32-wasip1`
* `wasm32-wasip2`
* `wasm32v1-none`

Notably it's possible to use `-Cpanic=unwind` with `-Zbuild-std` and
it's also mentioned that there are no concrete proposals at this time to
adding a new set of targets which support unwinding. My hunch is that in
a few years' time it would make sense to enable it by default on these
targets (except for `wasm32v1-none`) but that's a problem for
future folks to debate. For now this is an attempt to document the
status quo.
@jieyouxu jieyouxu added the O-wasm Target: WASM (WebAssembly), http://webassembly.org/ label Oct 4, 2025
Copy link
Member

@jieyouxu jieyouxu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This makes sense, thanks

View changes since this review

@jieyouxu
Copy link
Member

jieyouxu commented Oct 4, 2025

r? jieyouxu @bors r+ rollup

@bors
Copy link
Collaborator

bors commented Oct 4, 2025

📌 Commit fd96a78 has been approved by jieyouxu

It is now in the queue for this repository.

@rustbot rustbot assigned jieyouxu and unassigned SparrowLii Oct 4, 2025
@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Oct 4, 2025
Zalathar added a commit to Zalathar/rust that referenced this pull request Oct 4, 2025
…r=jieyouxu

Add documentation about unwinding to wasm targets

This commit adds some documentation about the state of `-Cpanic=unwind` for the following wasm targets:

* `wasm32-unknown-unknown`
* `wasm32-wasip1`
* `wasm32-wasip2`
* `wasm32v1-none`

Notably it's possible to use `-Cpanic=unwind` with `-Zbuild-std` and it's also mentioned that there are no concrete proposals at this time to adding a new set of targets which support unwinding. My hunch is that in a few years' time it would make sense to enable it by default on these targets (except for `wasm32v1-none`) but that's a problem for future folks to debate. For now this is an attempt to document the status quo.
Zalathar added a commit to Zalathar/rust that referenced this pull request Oct 4, 2025
…r=jieyouxu

Add documentation about unwinding to wasm targets

This commit adds some documentation about the state of `-Cpanic=unwind` for the following wasm targets:

* `wasm32-unknown-unknown`
* `wasm32-wasip1`
* `wasm32-wasip2`
* `wasm32v1-none`

Notably it's possible to use `-Cpanic=unwind` with `-Zbuild-std` and it's also mentioned that there are no concrete proposals at this time to adding a new set of targets which support unwinding. My hunch is that in a few years' time it would make sense to enable it by default on these targets (except for `wasm32v1-none`) but that's a problem for future folks to debate. For now this is an attempt to document the status quo.
bors added a commit that referenced this pull request Oct 4, 2025
Rollup of 14 pull requests

Successful merges:

 - #142670 (Document fully-qualified syntax in `as`' keyword doc)
 - #145685 (add CloneFromCell and Cell::get_cloned)
 - #146330 (Bump unicode_data and printables to version 17.0.0)
 - #146451 (Fix atan2 inaccuracy in documentation)
 - #146479 (add mem::conjure_zst)
 - #146874 (compiler: Hint at multiple crate versions if trait impl is for wrong ADT )
 - #147117 (interpret `#[used]` as `#[used(compiler)]` on illumos)
 - #147190 (std: `sys::net` cleanups)
 - #147251 (Do not assert that a change in global cache only happens when concurrent)
 - #147280 (Return to needs-llvm-components being info-only)
 - #147288 (compiletest: Make `DirectiveLine` responsible for name/value splitting)
 - #147309 (Add documentation about unwinding to wasm targets)
 - #147315 (bless autodiff batching test)
 - #147323 (Fix top level ui tests check in tidy)

r? `@ghost`
`@rustbot` modify labels: rollup
matthiaskrgr added a commit to matthiaskrgr/rust that referenced this pull request Oct 4, 2025
…r=jieyouxu

Add documentation about unwinding to wasm targets

This commit adds some documentation about the state of `-Cpanic=unwind` for the following wasm targets:

* `wasm32-unknown-unknown`
* `wasm32-wasip1`
* `wasm32-wasip2`
* `wasm32v1-none`

Notably it's possible to use `-Cpanic=unwind` with `-Zbuild-std` and it's also mentioned that there are no concrete proposals at this time to adding a new set of targets which support unwinding. My hunch is that in a few years' time it would make sense to enable it by default on these targets (except for `wasm32v1-none`) but that's a problem for future folks to debate. For now this is an attempt to document the status quo.
bors added a commit that referenced this pull request Oct 5, 2025
Rollup of 6 pull requests

Successful merges:

 - #143900 ([rustdoc] Correctly handle `should_panic` doctest attribute and fix `--no-run` test flag on the 2024 edition)
 - #144908 (Fix doctest output json)
 - #147309 (Add documentation about unwinding to wasm targets)
 - #147328 (Implement non-poisoning `Mutex::with_mut`, `RwLock::with` and `RwLock::with_mut`)
 - #147337 (Make `fmt::Write` a diagnostic item)
 - #147349 (Improve the advice given by panic_immediate_abort)

r? `@ghost`
`@rustbot` modify labels: rollup
Zalathar added a commit to Zalathar/rust that referenced this pull request Oct 5, 2025
…r=jieyouxu

Add documentation about unwinding to wasm targets

This commit adds some documentation about the state of `-Cpanic=unwind` for the following wasm targets:

* `wasm32-unknown-unknown`
* `wasm32-wasip1`
* `wasm32-wasip2`
* `wasm32v1-none`

Notably it's possible to use `-Cpanic=unwind` with `-Zbuild-std` and it's also mentioned that there are no concrete proposals at this time to adding a new set of targets which support unwinding. My hunch is that in a few years' time it would make sense to enable it by default on these targets (except for `wasm32v1-none`) but that's a problem for future folks to debate. For now this is an attempt to document the status quo.
Zalathar added a commit to Zalathar/rust that referenced this pull request Oct 5, 2025
…r=jieyouxu

Add documentation about unwinding to wasm targets

This commit adds some documentation about the state of `-Cpanic=unwind` for the following wasm targets:

* `wasm32-unknown-unknown`
* `wasm32-wasip1`
* `wasm32-wasip2`
* `wasm32v1-none`

Notably it's possible to use `-Cpanic=unwind` with `-Zbuild-std` and it's also mentioned that there are no concrete proposals at this time to adding a new set of targets which support unwinding. My hunch is that in a few years' time it would make sense to enable it by default on these targets (except for `wasm32v1-none`) but that's a problem for future folks to debate. For now this is an attempt to document the status quo.
Zalathar added a commit to Zalathar/rust that referenced this pull request Oct 5, 2025
…r=jieyouxu

Add documentation about unwinding to wasm targets

This commit adds some documentation about the state of `-Cpanic=unwind` for the following wasm targets:

* `wasm32-unknown-unknown`
* `wasm32-wasip1`
* `wasm32-wasip2`
* `wasm32v1-none`

Notably it's possible to use `-Cpanic=unwind` with `-Zbuild-std` and it's also mentioned that there are no concrete proposals at this time to adding a new set of targets which support unwinding. My hunch is that in a few years' time it would make sense to enable it by default on these targets (except for `wasm32v1-none`) but that's a problem for future folks to debate. For now this is an attempt to document the status quo.
Zalathar added a commit to Zalathar/rust that referenced this pull request Oct 5, 2025
…r=jieyouxu

Add documentation about unwinding to wasm targets

This commit adds some documentation about the state of `-Cpanic=unwind` for the following wasm targets:

* `wasm32-unknown-unknown`
* `wasm32-wasip1`
* `wasm32-wasip2`
* `wasm32v1-none`

Notably it's possible to use `-Cpanic=unwind` with `-Zbuild-std` and it's also mentioned that there are no concrete proposals at this time to adding a new set of targets which support unwinding. My hunch is that in a few years' time it would make sense to enable it by default on these targets (except for `wasm32v1-none`) but that's a problem for future folks to debate. For now this is an attempt to document the status quo.
bors added a commit that referenced this pull request Oct 5, 2025
Rollup of 8 pull requests

Successful merges:

 - #143900 ([rustdoc] Correctly handle `should_panic` doctest attribute and fix `--no-run` test flag on the 2024 edition)
 - #147288 (compiletest: Make `DirectiveLine` responsible for name/value splitting)
 - #147309 (Add documentation about unwinding to wasm targets)
 - #147310 (Mark `PatternTypo` suggestion as maybe incorrect)
 - #147320 (Avoid to suggest pattern match on the similarly named in fn signature)
 - #147328 (Implement non-poisoning `Mutex::with_mut`, `RwLock::with` and `RwLock::with_mut`)
 - #147337 (Make `fmt::Write` a diagnostic item)
 - #147349 (Improve the advice given by panic_immediate_abort)

r? `@ghost`
`@rustbot` modify labels: rollup
bors added a commit that referenced this pull request Oct 5, 2025
Rollup of 7 pull requests

Successful merges:

 - #147288 (compiletest: Make `DirectiveLine` responsible for name/value splitting)
 - #147309 (Add documentation about unwinding to wasm targets)
 - #147310 (Mark `PatternTypo` suggestion as maybe incorrect)
 - #147320 (Avoid to suggest pattern match on the similarly named in fn signature)
 - #147328 (Implement non-poisoning `Mutex::with_mut`, `RwLock::with` and `RwLock::with_mut`)
 - #147337 (Make `fmt::Write` a diagnostic item)
 - #147349 (Improve the advice given by panic_immediate_abort)

r? `@ghost`
`@rustbot` modify labels: rollup
@bors bors merged commit ff86a7d into rust-lang:master Oct 5, 2025
10 checks passed
@rustbot rustbot added this to the 1.92.0 milestone Oct 5, 2025
rust-timer added a commit that referenced this pull request Oct 5, 2025
Rollup merge of #147309 - alexcrichton:wasm-unwinding-docs, r=jieyouxu

Add documentation about unwinding to wasm targets

This commit adds some documentation about the state of `-Cpanic=unwind` for the following wasm targets:

* `wasm32-unknown-unknown`
* `wasm32-wasip1`
* `wasm32-wasip2`
* `wasm32v1-none`

Notably it's possible to use `-Cpanic=unwind` with `-Zbuild-std` and it's also mentioned that there are no concrete proposals at this time to adding a new set of targets which support unwinding. My hunch is that in a few years' time it would make sense to enable it by default on these targets (except for `wasm32v1-none`) but that's a problem for future folks to debate. For now this is an attempt to document the status quo.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
O-wasm Target: WASM (WebAssembly), http://webassembly.org/ S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants