-
Notifications
You must be signed in to change notification settings - Fork 177
Improve testing text #3447
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
Improve testing text #3447
Conversation
match Queue.peek t.events with | ||
| None -> () | ||
| Some time -> | ||
if Time_ns.Span.( >= ) (Time_ns.diff t.now time) t.period |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a little hard to read. Perhaps break up into two lines?
let diff = Time_ns.diff t.now time in
if Time_ns.Span.(diff >= t.period)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't like the proposed style because it opens up Span and it's unclear what identifiers might be shadowed in such expressions.
Really, we need modular implicits to make this kind of code nice! (And Flambda, to make it fast again.)
No description provided.