Skip to content
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

Derive Sync and Send #101

Open
michalmoc opened this issue Nov 25, 2021 · 1 comment
Open

Derive Sync and Send #101

michalmoc opened this issue Nov 25, 2021 · 1 comment

Comments

@michalmoc
Copy link

Send and sync are implemented by default only when all generic arguments are send/sync, which is not always necessary. To get them without bounds one needs to write

unsafe impl<T> Send for SomeType<T> {}
unsafe impl<T> Sync for SomeType<T> {}

for every such type. It would be more convenient to have #[derivative(Sync(bounds=""), Send(bounds=""))].

@toyboot4e
Copy link

toyboot4e commented Nov 27, 2021

Same applies to Default, though I don't mind the redundant (bounds = ""). Both default boundaries make sense.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants