Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Absolute paths are not correct for re-exported items #29871

Closed
mitaa opened this issue Nov 16, 2015 · 1 comment
Closed

Absolute paths are not correct for re-exported items #29871

mitaa opened this issue Nov 16, 2015 · 1 comment

Comments

@mitaa
Copy link
Contributor

mitaa commented Nov 16, 2015

(extracted from #1920)

@nikomatsakis

Another related issue here is that we have no way to take into account re-exports -- see the reference to core, for example, and not std.
(Handling re-exports may require some sort of annotations though.)

fn assert_clone<T>() where T : Clone { }

fn main() {
    assert_clone::<std::sync::atomic::AtomicBool>();
}
<anon>:4:5: 4:50 error: the trait `core::clone::Clone` is not implemented for the type `core::sync::atomic::AtomicBool` [E0277]
<anon>:4     assert_clone::<std::sync::atomic::AtomicBool>();
             ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

This should show std::clone::Clone and std::sync::atomic::AtomicBool since core isn't even linked into or reachable from the local crate.

@mitaa mitaa changed the title Absolute paths are not correct for external re-exported items Absolute paths are not correct for re-exported items Nov 16, 2015
@apasel422
Copy link
Contributor

See #23224, #23355, #26635, #27165.

@mitaa mitaa closed this as completed Nov 17, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants