-
Notifications
You must be signed in to change notification settings - Fork 13k
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
--emit=metadata
emitting empty .rmeta file
#67293
Comments
--emit metadata
emitting empty .rmeta file--emit=metadata
emitting empty .rmeta file
I would be cautious with this, as it could be a noticeable increase in disk usage for some projects. Rust already uses too much disk space. There should probably be a stronger reason than "it seems like it should". |
Emitting an empty .rmeta file makes sense, as the metadata is what is needed to use it with |
Definitely. IMO, user's explicit request should be honored; therefore, in this case, the explicit request is On the other side, I agree with @bjorn3 's point that the metadata is not needed for certain crate types; however, under this scenario, I feel rustc should print an error or warning message instead of silently generating an empty file. |
Does it mean these projects request |
Does |
Yes. this is how |
Why is cargo passing |
At present,
rustc --emit=metadata foo.rs
generates an empty rmeta file namedlibfoo.rmeta
. The logic behind is that rmeta is not needed for certain crate types. However, I feel we should still save it to a file when user explicitly requested it by--emit=metadata
, especially the metadata is always available in memory regardless of output crate types.The text was updated successfully, but these errors were encountered: