-
Notifications
You must be signed in to change notification settings - Fork 13.3k
Private lang items should be exported symbols #11591
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
Comments
Either this or require that they are |
I think I disagree. Lang items should be public - for the most part they are used just like any other item. |
Though there is some appeal to being able to hide lang items that aren't part of the public API. |
I don't think we'll ever expect someone to use a lang item directly, and for an executable there's no need for lang items to be public, there's not even a need for them to be reachable really. I suppose we could just require that libraries have public lang items? Regardless, this seems like kinda a corner case to me because there's not that much interaction with lang items. |
I'm actually surprised that this example compiled. I guess something in rustc was ignoring visibility when encoding calls to |
Fails to compile with linking errors:
The text was updated successfully, but these errors were encountered: