Adding implementations of `close-input-port` and `close-output-port`