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

Make sure to_rdf output is Send #79

Merged
merged 2 commits into from
Jul 9, 2024
Merged

Conversation

timothee-haudebourg
Copy link
Owner

@timothee-haudebourg timothee-haudebourg commented Jul 9, 2024

The JsonLdProcessor::to_rdf function is triggering rust-lang/rust#100013, making it unusable in a multi-threaded environment since the compiler is unable to check that the output (a Future) of to_rdf is Send. The only fix I know is to remove all the lifetime related to this function.

Instead of passing the vocabulary and generator by reference, they are now passed by move. As far as I know this is not an issue since VocabularyMut is also implemented for &mut V and Generator for &mut G anyway, so it's still possible to pass them by reference.

This is yet another breaking change though...

@timothee-haudebourg timothee-haudebourg merged commit daf8ebc into main Jul 9, 2024
2 checks passed
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

Successfully merging this pull request may close these issues.

1 participant