diff options
| author | Nic Gaffney <gaffney_nic@protonmail.com> | 2023-06-28 23:55:00 -0500 |
|---|---|---|
| committer | Nic Gaffney <gaffney_nic@protonmail.com> | 2023-06-28 23:55:00 -0500 |
| commit | dd3906c96555805af2580d593cf9429170b07a02 (patch) | |
| tree | a2f3974b325e4b31d3833a828dec7447108c0fb1 /examples/client.sloth | |
| parent | c4d6a1229c35cc889a1db53cf1c9d87d2f662238 (diff) | |
| download | sloth-dd3906c96555805af2580d593cf9429170b07a02.tar.gz | |
sockets
Diffstat (limited to 'examples/client.sloth')
| -rw-r--r-- | examples/client.sloth | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/examples/client.sloth b/examples/client.sloth new file mode 100644 index 0000000..8b7f737 --- /dev/null +++ b/examples/client.sloth @@ -0,0 +1,9 @@ +fn main() Int { + var sockint: Int = clientsock(); + println(recvsock(sockint)); + while true { + sendsock(readln(), sockint); + } + closesock(sockint); + return 0; +} |
