Esc

Socket

typeSource
  • macOS: Socket works on macOS
  • Linux: Socket works on Linux
  • Windows: Socket works on Windows
  • Wasm: Socket works on Wasm

A socket handle: Winsock's SOCKET here, an s32 file descriptor on Unix. Compare against INVALID_SOCKET, never a number.

Example
s: Socket = INVALID_SOCKET;
assert(s == INVALID_SOCKET);

Every system

SOCKET

Every system

s32

A socket handle: the file descriptor. Compare a handle against INVALID_SOCKET, never against a number.

Every system

s32

A socket handle: an s32 file descriptor here, Winsock's SOCKET on Windows. Compare against INVALID_SOCKET, never a number.

Example
s: Socket = INVALID_SOCKET;
assert(s == INVALID_SOCKET);

See also