-
Notifications
You must be signed in to change notification settings - Fork 12.7k
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
Error for instantiating tuple struct with private field has regressed on nightly #39703
Comments
The error was detected by a special code in |
Made a couple example playgrounds in a duplicate I made (#46407): Here we see that when using an absolute path to the struct we get the misleading error: playground. Here we see that adding a It's also worth noting that this misleading error is not only on nightly -- it is also on stable. |
Current output:
|
FWIW, this caught me just now and although just a short google away, it still had me scratching my head for a bit!
rustc 1.36.0 (a53f9df 2019-07-03) For those who reach this issue and still have not resolved the error, you must add pub struct Link(pub Address); |
Mention that tuple structs are private if any of their fields are CC rust-lang#39703
Mention that tuple structs are private if any of their fields are CC rust-lang#39703
On stable/beta, the error message is very good:
On nightly, it's flat out lying to the user:
The text was updated successfully, but these errors were encountered: