Skip to content

Commit

Permalink
Fixes a couple of examples (consistent use of time impl/jobs).
Browse files Browse the repository at this point in the history
  • Loading branch information
yomimono committed Jul 28, 2016
1 parent c43b3fb commit f061528
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions console/config.ml
@@ -1,7 +1,7 @@
open Mirage

let main =
foreign "Unikernel.Main" (console @-> job)
foreign "Unikernel.Main" (console @-> time @-> job)

let () =
register "console" [main $ default_console]
register "console" [main $ default_console $ default_time ]
4 changes: 2 additions & 2 deletions console/unikernel.ml
@@ -1,8 +1,8 @@
open Lwt.Infix

module Main (C: V1_LWT.CONSOLE) (T: V1_LWT.TIME) = struct
module Main (C: V1_LWT.CONSOLE) (Time: V1_LWT.TIME) = struct

let start c =
let start c _time =
let rec loop = function
| 0 -> Lwt.return_unit
| n ->
Expand Down
2 changes: 1 addition & 1 deletion io_page/unikernel.ml
Expand Up @@ -6,7 +6,7 @@ let sp = Printf.sprintf

module Main (Time: V1_LWT.TIME) (C: V1_LWT.CONSOLE) = struct

let start c =
let start _time c =
let one_page = P.get 1 in
let cstruct_page = P.to_cstruct one_page in
let cstruct_first_100bytes = Cstruct.sub cstruct_page 0 100 in
Expand Down

0 comments on commit f061528

Please sign in to comment.