diff options
author | Alex AUVOLAT <alex.auvolat@ens.fr> | 2014-05-20 11:14:01 +0200 |
---|---|---|
committer | Alex AUVOLAT <alex.auvolat@ens.fr> | 2014-05-20 11:14:01 +0200 |
commit | c5e69a904e79e807c5b075c08ce82183133e7b4c (patch) | |
tree | 4e629a9c2b653660dc438f1c37d58e8fbf3870d6 /src/primes.ml | |
parent | acfa0090d68a21be6c83815f484142b4eb814f4a (diff) | |
download | SystemeReseaux-Projet-c5e69a904e79e807c5b075c08ce82183133e7b4c.tar.gz SystemeReseaux-Projet-c5e69a904e79e807c5b075c08ce82183133e7b4c.zip |
Stuff.
Diffstat (limited to 'src/primes.ml')
-rw-r--r-- | src/primes.ml | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/src/primes.ml b/src/primes.ml index 11f5387..b9a57ed 100644 --- a/src/primes.ml +++ b/src/primes.ml @@ -23,9 +23,7 @@ module Primes (K : Kahn.S) = struct in loop() let rec primes (qi : int in_port) : unit process = - bind_io - (get qi) - (fun v -> + (get qi) >>= (fun v -> if v <> -1 then begin Format.printf "%d@." v; @@ -36,7 +34,7 @@ module Primes (K : Kahn.S) = struct let main : unit process = (delay new_channel ()) >>= - (fun (q_in, q_out) -> doco [ integers 1000 q_out ; primes q_in ]) + (fun (q_in, q_out) -> doco [ integers 2000 q_out ; primes q_in ]) end |