Skip to content

Commit

Permalink
Mark gimli-symbolize feature as deprecated
Browse files Browse the repository at this point in the history
The backtrace library no longer supports swapping the symbolization
library and always picks gimli (indirectly via addr2line crate). gimli
also has a lot fewer dependencies these days.
  • Loading branch information
athre0z committed Oct 22, 2023
1 parent 29a7a90 commit 1b32a77
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 17 deletions.
6 changes: 4 additions & 2 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,12 @@ keywords = [
]

[features]
default = ["gimli-symbolize"]
gimli-symbolize = ["backtrace/gimli-symbolize"]
default = []
resolve-modules = ["regex"]

# Deprecated, no longer has any effect: backtrace crate removed corresponding option.
gimli-symbolize = []

[dependencies]
termcolor = "1.1.2"
backtrace = "0.3.57"
Expand Down
15 changes: 0 additions & 15 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,21 +41,6 @@ BacktracePrinter::new().message("Custom message!").install(default_output_stream
- Hide all the frames after the panic was already initiated
- Hide language runtime initialization frames

### Reducing transitive dependencies

In order to reduce transitive dependencies, you can disable the default
enabled `gimli-symbolize` feature by adding a `default-features = false`
clause to your `Cargo.toml` dependency entry, e.g.:

```toml
[dependencies]
color-backtrace = { version = "0.6", default-features = false }
```

This will reduce dependencies from ~50 → ~10. However, you'll pay for it with
[inaccurate source info](https://github.com/athre0z/color-backtrace/issues/2)
on macOS and Linux

### Usage in tests

Unfortunately, defining custom init functions run before tests are started is
Expand Down

0 comments on commit 1b32a77

Please sign in to comment.