Skip to content

Commit 32ea926

Browse files
Merge pull request #15 from avsm/errata-1
Errata 1 for latest Core/Async
2 parents 942fe3c + da57631 commit 32ea926

9 files changed

+12
-11
lines changed

INSTALL.sh

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#!/bin/sh
22

3-
opam install --yes \
3+
opam install -j 4 --yes \
44
core \
55
core_extended \
66
cryptokit \
@@ -16,7 +16,8 @@ opam install --yes \
1616
cmdliner \
1717
cow \
1818
ocp-indent \
19-
ctypes
19+
ctypes \
20+
ocp-index
2021

2122
echo You also need Pygments installed.
2223
echo This is python-pygments in Debian

code/async/search.ml

+1-1
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ let get_definition_from_json json =
2828
let get_definition word =
2929
Cohttp_async.Client.get (query_uri word)
3030
>>= fun (_, body) ->
31-
Pipe.to_list body
31+
Pipe.to_list (Cohttp_async.Body.to_pipe body)
3232
>>| fun strings ->
3333
(word, get_definition_from_json (String.concat strings))
3434

code/async/search_with_error_handling.ml

+1-1
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ let get_definition ~server word =
3030
try_with (fun () ->
3131
Cohttp_async.Client.get (query_uri ~server word)
3232
>>= fun (_, body) ->
33-
Pipe.to_list body
33+
Pipe.to_list (Cohttp_async.Body.to_pipe body)
3434
>>| fun strings ->
3535
(word, get_definition_from_json (String.concat strings)))
3636
>>| function

code/async/search_with_timeout_no_leak.ml

+1-1
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ let get_definition ~server ~interrupt word =
2929
try_with (fun () ->
3030
Cohttp_async.Client.get ~interrupt (query_uri ~server word)
3131
>>= fun (_, body) ->
32-
Pipe.to_list body
32+
Pipe.to_list (Cohttp_async.Body.to_pipe body)
3333
>>| fun strings ->
3434
(word, get_definition_from_json (String.concat strings)))
3535
>>| function

code/async/test.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
THIS IS ONLY A TEST.
1+
This is only a test.

code/ffi/datetime.ml

+2-2
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,8 @@ let () = seal timeval
1616
type timezone
1717
let timezone : timezone structure typ = structure "timezone"
1818

19-
let gettimeofday = foreign "gettimeofday"
20-
(ptr timeval @-> ptr timezone @-> returning_checking_errno int)
19+
let gettimeofday = foreign "gettimeofday" ~check_errno:true
20+
(ptr timeval @-> ptr timezone @-> returning int)
2121

2222
let time' () = time (from_voidp time_t null)
2323

code/gc/run_barrier_bench.sh

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
corebuild -pkg core_bench barrier_bench.native
2-
./barrier_bench.native -ascii name alloc
2+
./barrier_bench.native -ascii alloc
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
corebuild -pkg core_bench map_vs_hash.native
2-
./map_vs_hash.native -ascii -clear-columns name time speedup
2+
./map_vs_hash.native -ascii -clear-columns time speedup
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
corebuild -pkg core_bench map_vs_hash2.native
2-
./map_vs_hash2.native -ascii -clear-columns name time speedup
2+
./map_vs_hash2.native -ascii -clear-columns time speedup

0 commit comments

Comments
 (0)