-
Notifications
You must be signed in to change notification settings - Fork 14
compatibility with lwt.6 #55
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
base: master
Are you sure you want to change the base?
Changes from all commits
213d585
0e2a76b
048634d
ce8acf6
f1b5744
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -61,6 +61,13 @@ let call_me_maybe f x = | |||||||||||||||||||||||||||
| and poll is guaranteed to be available without the fd limitation. | ||||||||||||||||||||||||||||
| *) | ||||||||||||||||||||||||||||
| let () = | ||||||||||||||||||||||||||||
| if not (Lwt_config._HAVE_LIBEV && Lwt_config.libev_default) then begin | ||||||||||||||||||||||||||||
| match Lwt_engine.id () with | ||||||||||||||||||||||||||||
| | Lwt_engine.Engine_id__libev _ -> () | ||||||||||||||||||||||||||||
| | Lwt_engine.Engine_id__select -> | ||||||||||||||||||||||||||||
| (* Otherwise, prefer poll over select, because select can only monitor fds up to 1024, | ||||||||||||||||||||||||||||
| and poll is guaranteed to be available without the fd limitation. *) | ||||||||||||||||||||||||||||
| Lwt_engine.set @@ new Lwt_engines.poll | ||||||||||||||||||||||||||||
| end | ||||||||||||||||||||||||||||
| | Lwt_engine.Engine_id__poll -> () | ||||||||||||||||||||||||||||
|
Comment on lines
+65
to
+70
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||||||||||||||||||||||||
| | lwteng -> | ||||||||||||||||||||||||||||
| eprintfn "Unknown Lwt engine (%s) in use, leaving as is" Obj.Extension_constructor.(name (of_val lwteng)); | ||||||||||||||||||||||||||||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. i see Obj i suspect
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. i can make that change
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. this comment remains, no need to log when we dont change anything, only need to log when switching select=>poll |
||||||||||||||||||||||||||||
| () | ||||||||||||||||||||||||||||
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.
is this method not available in lwt 6?
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.
it is available
is the concern that then we don't have a version of devkit that's compatible with both 5.9 and 6 so it makes the upgrade for users more difficult? if that's the case then i have ocsigen/lwt#1106 in the works to allow specifically for that
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.
yes, would prefer to be less disruptive