mirror of
https://github.com/rust-lang/rust.git
synced 2024-12-11 08:05:12 +00:00
f7b2e37f72
There is already a workaround in `compiletest` to deal with custom `CARGO_HOME` using `-Zignore-directory-in-diagnostics-source-blocks={}`. A similar need exists when dependencies come from the local `vendor` directory, which distro builds often use, so now we ignore that too. Also, `issue-21763.rs` was normalizing `hashbrown-` paths, presumably expecting a version suffix, but the vendored path doesn't include the version. Now that matches `[\\/]hashbrown` instead.
14 lines
341 B
Rust
14 lines
341 B
Rust
// Regression test for HashMap only impl'ing Send/Sync if its contents do
|
|
|
|
//@ normalize-stderr-test: "\S+[\\/]hashbrown\S+" -> "$$HASHBROWN_SRC_LOCATION"
|
|
|
|
use std::collections::HashMap;
|
|
use std::rc::Rc;
|
|
|
|
fn foo<T: Send>() {}
|
|
|
|
fn main() {
|
|
foo::<HashMap<Rc<()>, Rc<()>>>();
|
|
//~^ ERROR `Rc<()>` cannot be sent between threads safely
|
|
}
|