```
# #require "ZMQ";;
# let ctx = ZMQ.Context.create ();;
val ctx : ZMQ.Context.t = <abstr>
# let sock = ZMQ.Socket.create ctx ZMQ.Socket.req;;
val sock : _[> `Req ] ZMQ.Socket.t = <abstr>
# ZMQ.Socket.close sock;;
- : unit = ()
# ZMQ.Socket.close sock;;
Exception: Unix.Unix_error (Unix.ENOTSOCK, "zmq_close", "").
```