File tree Expand file tree Collapse file tree 1 file changed +19
-3
lines changed Expand file tree Collapse file tree 1 file changed +19
-3
lines changed Original file line number Diff line number Diff line change @@ -1680,11 +1680,13 @@ cargo-features = ["open-namespaces"]
16801680* Tracking Issue: [ #16042 ] ( https://github.com/rust-lang/cargo/issues/16042 )
16811681* Upstream Tracking Issue: [ rust-lang/rust #147286 ] ( https://github.com/rust-lang/rust/issues/147286 )
16821682
1683- Allow use of [ ` -Cpanic=immediate-abort ` ] ( ../../rustc/codegen-options/index.html# panic) through a Cargo profile
1684-
1683+ Extends the ` panic ` profile setting to support the
1684+ [ ` immediate-abort ` ] ( ../../rustc/codegen-options/index.html#panic ) panic strategy.
16851685This can be enabled like so:
1686+
16861687``` toml
1687- cargo-features = [" immediate-abort" ]
1688+ # Cargo.toml
1689+ cargo-features = [" panic-immediate-abort" ]
16881690
16891691[package ]
16901692# ...
@@ -1693,6 +1695,20 @@ cargo-features = ["immediate-abort"]
16931695panic = " immediate-abort"
16941696```
16951697
1698+ To set this in a profile in Cargo configuration,
1699+ you need to use either ` -Z panic-immediate-abort ` CLI flag
1700+ or the ` [unstable] ` table to enable it.
1701+ For example,
1702+
1703+ ``` toml
1704+ # .cargo/config.toml
1705+ [unstable ]
1706+ panic-immediate-abort = true
1707+
1708+ [profile .release ]
1709+ panic = " immediate-abort"
1710+ ```
1711+
16961712## ` [lints.cargo] `
16971713
16981714* Tracking Issue: [ #12235 ] ( https://github.com/rust-lang/cargo/issues/12235 )
You can’t perform that action at this time.
0 commit comments