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

Add OCaml 4.14 support #244

Merged
merged 3 commits into from
Nov 29, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions capnp-rpc-mirage.opam
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ depends: [
"dns-client" {>= "6.0.0"}
"tls-mirage"
"mirage-stack" {>= "2.2.0"}
"mirage-protocols" {>= "6.0.0"}
"arp" {>= "2.3.0" & with-test}
"alcotest" {>= "1.0.1" & with-test}
"alcotest-lwt" {>= "1.0.1" & with-test}
Expand Down
5 changes: 4 additions & 1 deletion capnp-rpc/struct_proxy.ml
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,10 @@ module Make (C : S.CORE_TYPES) = struct
| PromiseField p -> p.sr#field_sealed_dispatch p.path brand
end

class virtual ['promise] t init = object (self : #C.struct_ref)
class virtual ['promise] t init = object (self : 'self)
constraint 'self = #C.struct_ref
constraint 'self = #C.struct_resolver

val mutable state =
Unresolved {
target = init;
Expand Down
2 changes: 1 addition & 1 deletion mirage/capnp_rpc_mirage.ml
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ module Make (R : Mirage_random.S) (T : Mirage_time.S) (M : Mirage_clock.MCLOCK)
in
match listen_address with
| `TCP port ->
Stack.listen_tcp t.stack ~port (fun flow ->
Stack.TCP.listen (Stack.tcp t.stack) ~port (fun flow ->
Log.info (fun f -> f ?tags "Accepting new connection");
let secret_key = if serve_tls then Some (Vat_config.secret_key config) else None in
Lwt.async (fun () -> handle_connection ?tags ~secret_key vat flow);
Expand Down
2 changes: 1 addition & 1 deletion test-mirage/test_mirage.ml
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ module Stack = struct
module Icmp = Icmpv4.Make(I4)
include Tcpip_stack_direct.MakeV4V6(Time)(Random)(V)(E)(A)(I)(Icmp)(U)(T)

let create_network () = B.create ~use_async_readers:true ~yield:Lwt_unix.yield ()
let create_network () = B.create ~use_async_readers:true ~yield:Lwt.pause ()

let create_interface backend cidr =
V.connect backend >>= fun v ->
Expand Down