-
-
Notifications
You must be signed in to change notification settings - Fork 43
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
Does not collect plugins defined outside of crate root #9
Comments
Hmm. I'm not having issues with my usage of |
I'm having a similar issue where plugins are only registered if the module they are submitted in has publicly-exposed functions. Is there a fix for this? (If it's important, I'm running this on Ubuntu. I haven't tried anything yet on Windows.) |
That may be a limitation of the linker model. I know at least on Mach-O (macOS), statics are not guaranteed to be initialized before a symbol from the object they live in is needed (this affects static builds in particular). Maybe ELF has a similar mode, but it isn't being used here? Feels like more of an LLVM codegen thing to me though. |
This is fixed in rustc 1.62.0 / inventory 0.3.0. |
Using:
inventory
version0.1.3
(have^0.1
defined in my manifest)rustc 1.34.0-nightly (b139669f3 2019-02-06)
cargo 1.34.0-nightly (4e74e2fc0 2019-02-02)
main.rs
commands/mod.rs
Output is as follows:
The text was updated successfully, but these errors were encountered: