Closed
Description
Not sure if this is the correct solution, but I'm looking at untangling libstd so it can be built freestanding.
The deriving syntax is good, but if you want to make part of it conditional you can't. Looking at #11968, Eq and Clone have to be done with the impl written out in full, be easier to do
derive!(marker::CovariantType<T>, (Eq, Clone))
And if libprim is replaced with #[cfg] tags, you can do
#[lang="covariant_type"]
pub struct CovariantType<T>;
#[cfg(with_alloc)] derive!(CovariantType<T>, (Eq, Clone))
Or maybe these should just be written out in full?
Metadata
Metadata
Assignees
Labels
No labels