about summary refs log tree commit diff
path: root/src/libstd/backtrace.rs
AgeCommit message (Collapse)AuthorLines
2020-03-20remove redundant returns (clippy::needless_return)Matthias Krüger-1/+1
2020-03-09Write backtrace fmt test using relative pathsDavid Tolnay-5/+5
For some reason the absolute paths were formatted differently on the armhf-gnu target. thread '<unnamed>' panicked at 'assertion failed: `(left == right)` left: `"Backtrace [\n { fn: \"__rust_maybe_catch_panic\" },\n { fn: \"std::rt::lang_start_internal\", file: \"./rust/rt.rs\", line: 300 },\n { fn: \"std::rt::lang_start\", file: \"./rust/rt.rs\", line: 400 },\n]"`, right: `"Backtrace [\n { fn: \"__rust_maybe_catch_panic\" },\n { fn: \"std::rt::lang_start_internal\", file: \"/rust/rt.rs\", line: 300 },\n { fn: \"std::rt::lang_start\", file: \"/rust/rt.rs\", line: 400 },\n]"`', src/libstd/backtrace.rs:486:5
2020-03-09Add test of Debug representation of BacktraceDavid Tolnay-0/+52
2020-03-09Make it possible to instantiate hardcoded Backtrace from testDavid Tolnay-3/+28
2020-03-09Change disabled and unsupported backtraces to print using placeholder styleDavid Tolnay-2/+2
2020-03-09Add quotes around filename in Backtrace debugDavid Tolnay-1/+1
2020-03-09Remove quotes around unknown fn placeholder in backtraceDavid Tolnay-1/+1
2020-02-28use is_empty() instead of len() == x to determine if structs are empty.Matthias Krüger-1/+1
2020-02-11remove intentionally failing testJane Lusby-18/+0
2020-02-10backwards again, god damnitJane Lusby-1/+1
2020-02-10rule over the code in libstd with an iron fistJane Lusby-9/+4
2020-02-10maximum alternative consistency!Jane Lusby-2/+9
2020-02-10make symbol printing consistent with backtrace_rsJane Lusby-2/+3
2020-02-10add nice alt fmt for debugJane Lusby-6/+6
2020-02-10use debug_map and skip empty framesJane Lusby-5/+10
2020-02-10remove Some from fn nameJane Lusby-1/+1
2020-02-10final format cleanupsJane Lusby-1/+8
2020-02-10make it compileJane Lusby-1/+1
2020-02-10remove unnecessary Debug impl for BacktraceFrameJane Lusby-6/+0
2020-02-10remove unnecessary derivesJane Lusby-2/+0
2020-02-10less noisy formatJane Lusby-7/+37
2020-02-10Get vaguely working with a test for checking outputJane Lusby-1/+26
2020-02-10Add initial debug fmt for BacktraceJane Lusby-6/+19
2019-11-29Format libstd with rustfmtDavid Tolnay-2/+2
This commit applies rustfmt with rust-lang/rust's default settings to files in src/libstd *that are not involved in any currently open PR* to minimize merge conflicts. THe list of files involved in open PRs was determined by querying GitHub's GraphQL API with this script: https://gist.github.com/dtolnay/aa9c34993dc051a4f344d1b10e4487e8 With the list of files from the script in outstanding_files, the relevant commands were: $ find src/libstd -name '*.rs' \ | xargs rustfmt --edition=2018 --unstable-features --skip-children $ rg libstd outstanding_files | xargs git checkout -- Repeating this process several months apart should get us coverage of most of the rest of libstd. To confirm no funny business: $ git checkout $THIS_COMMIT^ $ git show --pretty= --name-only $THIS_COMMIT \ | xargs rustfmt --edition=2018 --unstable-features --skip-children $ git diff $THIS_COMMIT # there should be no difference
2019-10-02BacktraceStatus: add Eq implBen Boeckel-1/+1
See discussion on #53487.
2019-09-14rename the crate, not the featureRalf Jung-0/+1
2019-09-09std: Add a `backtrace` moduleAlex Crichton-0/+352
This commit adds a `backtrace` module to the standard library, as designed in [RFC 2504]. The `Backtrace` type is intentionally very conservative, effectively only allowing capturing it and printing it. Additionally this commit also adds a `backtrace` method to the `Error` trait which defaults to returning `None`, as specified in [RFC 2504]. More information about the design here can be found in [RFC 2504] and in the [tracking issue]. Implementation-wise this is all based on the `backtrace` crate and very closely mirrors the `backtrace::Backtrace` type on crates.io. Otherwise it's pretty standard in how it handles everything internally. [RFC 2504]: https://github.com/rust-lang/rfcs/blob/master/text/2504-fix-error.md [tracking issue]: https://github.com/rust-lang/rust/issues/53487 cc #53487