-
Notifications
You must be signed in to change notification settings - Fork 85
Replace __ONCE__ with Cargo links key #276
Conversation
(rust_highfive has picked a reviewer for you, use r? to override) |
👍 to adding |
In cortex-m, the static you're talking about is The issue here is that because the static is zero sized, disassemblers mix it up with whatever other statics end up at the same address. Nevertheless you're totally right and removing the static in the same release as adding the links key does stop duplicate detection between versions which is a pain. Any other ideas for fixing the debug issue? Making the static non-zero-sized seems undesirable. |
Ah, I see, yeah. That static has another purpose and need to be kept. I don't immediately see how to fix this debugging issue other than fixing the debug tooling (which arguably is the "proper" fix). |
@jonas-schievink I've updated to keep ONCE (though added a comment about this) and still add the links key, which I guess i the best we can do for now. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
bors r+
Build succeeded: |
I guess we should release this ASAP then? |
I don't think we'll want to remove |
Yes, a patch release to get "links" out into the field. |
Sure, it's worth doing eventually, but there's no rush since it won't make any difference until there's two releases using it (which could then be detected attempting to link together). |
Maybe I'm a bit over-cautious but I'm wary about any new problems which could occur with the |
This would fix #275. We use the links key in cortex-m already here. See also rust-embedded/wg#467.