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

SyncVar.take should have overload with timeout #5623

Closed
scabug opened this issue Mar 27, 2012 · 2 comments
Closed

SyncVar.take should have overload with timeout #5623

scabug opened this issue Mar 27, 2012 · 2 comments
Assignees
Milestone

Comments

@scabug
Copy link

scabug commented Mar 27, 2012

SyncVar has overloads of get with and without timeout. take only has a no-timeout overload. Adding one with timeout would be trivial, I think:

def take(timeout: Long) = synchronized {
try get(timeout)
finally unset()
}

@scabug
Copy link
Author

scabug commented Mar 27, 2012

Imported From: https://issues.scala-lang.org/browse/SI-5623?orig=1
Reporter: Seth LaForge (sethml)

@scabug
Copy link
Author

scabug commented May 18, 2012

@heathermiller said:
Good suggestion, added in ce896d6

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

No branches or pull requests

2 participants