Websocket.connect.tcp: def of bend-kit-websocket@0.4.0.0 Import: import bend-kit-websocket@0.4.0.0/websocket.bend as Websocket Lines 912-924 of bend-kit-websocket@0.4.0.0/websocket.bend: https://jend.leeeet.dev/read.txt?path=bend-kit-websocket@0.4.0.0/websocket.bend&start_line=912&end_line=924 import Base import bend-kit-wire@0.4.6.2/wire.bend as Wire def connect.tcp(c: Result<&1, &1, U32 & String, Socket>, +tls: Bool, +host: String, +authority: String, +path: String, +max: U32, +ms: U32) -> IO(Result<&1, &1, U32 & String, Conn>): match c: case Fail{e}: do IO>: return Fail{e} case Done{sock}: match tls: case True{}: do IO>: t : Socket & Result<&1, &1, U32 & String, Unit> <- Wire.tls.connect(sock, host, ms) connect.tls(t, authority, path, max, ms) case False{}: handshake(sock, False{}, authority, path, max, ms) Uses (14): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Bool https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=IO https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=IO.bind https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=IO.pure https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Pair https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Result https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Socket https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=String https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32 https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Unit https://jend.leeeet.dev/definition.txt?path=bend-kit-websocket@0.4.0.0/websocket.bend&name=Conn https://jend.leeeet.dev/definition.txt?path=bend-kit-websocket@0.4.0.0/websocket.bend&name=connect.tls https://jend.leeeet.dev/definition.txt?path=bend-kit-websocket@0.4.0.0/websocket.bend&name=handshake https://jend.leeeet.dev/definition.txt?path=bend-kit-wire@0.4.8.0/wire.bend&name=tls.connect