Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Use target dir that does not overlap with parent crate's
When reusing the original crate's target directory, crates compiled during trybuild's invocation of Cargo are incompatible from the ones compiled for the original test run but have colliding hashes on compilers newer than nightly-2019-10-03, causing failures to find the right crate during doc tests. Examples of such failures: ``` Doc-tests serde_json error[E0463]: can't find crate for `serde_derive` which `serde` depends on --> /home/travis/build/serde-rs/json/src/lib.rs:325:1 | 325 | extern crate serde; | ^^^^^^^^^^^^^^^^^^^ can't find crate ``` ``` ---- src/ext.rs - ext::TokenStreamExt::append_all (line 20) stdout ---- error[E0460]: found possibly newer version of crate `proc_macro2` which `quote` depends on --> src/ext.rs:19:1 | 2 | extern crate quote; | ^^^^^^^^^^^^^^^^^^^ | = note: perhaps that crate needs to be recompiled? = note: the following crate versions were found: crate `proc_macro2`: /home/travis/build/dtolnay/quote/target/debug/deps/libproc_macro2-e61df99964fc712a.rlib crate `proc_macro2`: /home/travis/build/dtolnay/quote/target/debug/deps/libproc_macro2-e61df99964fc712a.rmeta crate `proc_macro2`: /home/travis/build/dtolnay/quote/target/debug/deps/libproc_macro2-37a3c8079ede86c5.rmeta crate `quote`: /home/travis/build/dtolnay/quote/target/debug/deps/libquote-9e0852a9faf16dfb.rlib ```
- Loading branch information