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

sync: add merge() to semaphore permits #4948

Merged
merged 6 commits into from Sep 27, 2022

Commits on Aug 31, 2022

  1. sync: add merge() to semaphore permits

    Adds a merge() method to:
    
        * SemaphorePermit
        * OwnedSemaphorePermit
    
    Merging two permits instances together consumes one instance, adding the
    permits it holds to the remaining instance.
    domodwyer committed Aug 31, 2022
    Copy the full SHA
    91d1f7a View commit details
    Browse the repository at this point in the history
  2. fix: do not allow merging of unrelated Semaphores

    Prevent merging permits from two different Semaphore instances.
    Attempting to merge unrelated permits will panic.
    domodwyer committed Aug 31, 2022
    Copy the full SHA
    1ff74fb View commit details
    Browse the repository at this point in the history
  3. docs: document panics / track_caller

    Document merging permits from distinct Semaphore instances causes a
    panic, and add #[track_caller] annotation.
    domodwyer committed Aug 31, 2022
    Copy the full SHA
    ec172d4 View commit details
    Browse the repository at this point in the history
  4. Copy the full SHA
    39b9bf1 View commit details
    Browse the repository at this point in the history

Commits on Sep 19, 2022

  1. Copy the full SHA
    f8dc306 View commit details
    Browse the repository at this point in the history
  2. Copy the full SHA
    f45a699 View commit details
    Browse the repository at this point in the history