rust-lang / backtrace-rs

Backtraces in Rust
https://docs.rs/backtrace
Other
526 stars 245 forks source link

Remove `doc(html_root_url)` attribute #524

Closed GuillaumeGomez closed 1 year ago

GuillaumeGomez commented 1 year ago

I'm working on turning https://github.com/rust-lang/rust/issues/82730 into an error. When I did, the build for this crate failed because when included from libstd because of this attribute. This fixes it.

jyn514 commented 1 year ago

This doesn't seem like the right fix? it's possible to use backtrace as a dependency outside of std without enabling the std feature.

I'd suggest one of the following:

GuillaumeGomez commented 1 year ago

I think using backtrace as dependency rather than including it seems like a better approach. I'll check first why it was done this way.

GuillaumeGomez commented 1 year ago

This turns out to be actually quite tricky: backtrace cannot be built as a dependency of std apparently because it requires std, hence why it's included using path. I tried to go around for some time but the changes were quite massive and in the end, I'm not sure it's worth it. I decided to just remove the attribute to make things simpler for the time being. But it might be worth discussing simplifying the integration of backtrace into std.

GuillaumeGomez commented 1 year ago

This is ready then. Ping @JohnTitor

GuillaumeGomez commented 1 year ago

Thanks!