Close an output channel.
Signature: (close-output-channel channel state-state) returns
This is a logic-mode function, but its logical definition is tricky;
see logical-story-of-io. The main logical consequence is that
Under the hood, we close the raw Lisp stream associated with
Theorem:
(defthm state-p1-of-close-output-channel-free (implies (and (open-output-channel-p1 channel type state) (state-p1 state)) (state-p1 (close-output-channel channel state))))
Theorem:
(defthm state-p1-of-close-output-channel-types (implies (and (or (open-output-channel-p1 channel :byte state) (open-output-channel-p1 channel :object state) (open-output-channel-p1 channel :character state)) (state-p1 state)) (state-p1 (close-output-channel channel state))))
Theorem:
(defthm state-p1-of-close-output-channel-of-open (implies (and (open-output-channel-p1 (mv-nth 0 (open-output-channel fname type state1)) type state) (state-p1 state)) (state-p1 (close-output-channel (mv-nth 0 (open-output-channel fname type state1)) state))))