Closed lassade closed 1 year ago
I think no_std
has to be opted into with #![no_std]
. It controls linking so I could see it only need to be used in the binary crate but I have little experience with it. Does it need to be present in all dependencies? May be worth checking with cargo tree
that there aren’t any dependencies or dev-dependencies being brought in?
Nop there is no other std dependency.
This is happening because profiling doesn't have a #![no_std]
so even though no code is been generated from the macros the std
is still pulled into the dependency. That doesn't show on cargo tree
:)
It is possible this crate to no_std
maybe supporting only a couple of backends?
I don’t mind having this crate opt into no_std
for when no backend is enabled or if there is a backend that doesn’t need std
. I don’t know if any of the backends would support it though. If you want to PR something related to this I’d be happy to look! I’m not currently using rust on platforms that don’t have std
so I’m not sure if/when I would find time to do this myself.
Completed in #49
profiling = "1.0.7"
with no extra features can't be built with:I something like
profiling::scope!("sort");
shouldn't be generating any code at all but for some reason the compiles keeps likingstd
any ideas why?