Skip to content

Commit 668ed0d

Browse files
committed
adding comments.
1 parent 685cec5 commit 668ed0d

File tree

3 files changed

+4
-0
lines changed

3 files changed

+4
-0
lines changed

Network/Socket.hs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@
3939
-- > sendAll s msg
4040
-- > talk s
4141
-- >
42+
-- > -- from the "network-run" package.
4243
-- > runTCPServer :: Maybe HostName -> ServiceName -> (Socket -> IO a) -> IO a
4344
-- > runTCPServer mhost port server = withSocketsDo $ do
4445
-- > addr <- resolve
@@ -77,6 +78,7 @@
7778
-- > putStr "Received: "
7879
-- > C.putStrLn msg
7980
-- >
81+
-- > -- from the "network-run" package.
8082
-- > runTCPClient :: HostName -> ServiceName -> (Socket -> IO a) -> IO a
8183
-- > runTCPClient host port client = withSocketsDo $ do
8284
-- > addr <- resolve

examples/EchoClient.hs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ main = runTCPClient "127.0.0.1" "3000" $ \s -> do
1414
putStr "Received: "
1515
C.putStrLn msg
1616

17+
-- from the "network-run" package.
1718
runTCPClient :: HostName -> ServiceName -> (Socket -> IO a) -> IO a
1819
runTCPClient host port client = withSocketsDo $ do
1920
addr <- resolve

examples/EchoServer.hs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ main = runTCPServer Nothing "3000" talk
1717
sendAll s msg
1818
talk s
1919

20+
-- from the "network-run" package.
2021
runTCPServer :: Maybe HostName -> ServiceName -> (Socket -> IO a) -> IO a
2122
runTCPServer mhost port server = withSocketsDo $ do
2223
addr <- resolve

0 commit comments

Comments
 (0)