closes the stream corresponding to Stream.
If Stream is a stream object, then if the corresponding stream is
open, it will be closed; otherwise,
close/1 succeeds immediately,
taking no action.
If Stream is a file specification, the corresponding
stream will be closed, provided that the file was opened by
Stream errors (see ref-iou-sfh-est), plus:
In this example,
foo will be closed:
see(foo), ... close(foo)
However, in this example, a permission error will be raised and
will not be closed:
open(foo, read, S), ... close(foo)
close(S) should have been used.