Skip to content

Could gix_object::Find be async? #1388

Answered by Byron
NicholasLYang asked this question in Q&A
Discussion options

You must be logged in to vote

For something to be async, it must satisfy certain conditions like:

  • it does minimal work when polled
  • it is cancellable

This is simply not true unless the operation is performed in a thread, something you can do with tokio::spawn_blocking() for instance.

Due to that, the non-transport parts won't ever be async - it would be a lie.

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by Byron
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
enhancement New feature or request
2 participants
Converted from issue

This discussion was converted from issue #1387 on May 29, 2024 05:01.