13 This function closes the open file associated with the descriptor fd.
14 When this is done, the file value associated with the file remains
15 a file value, but appears 'closed', and cannot be used in further
16 file-related calls (except fclose) without causing errors. This same
17 action occurs to all copies of the file value. You do not need to
18 explicitly close all the copies of a file value.
20 Standard input, standard output and standard error are always opened
23 The truth value of a closed file is FALSE.
25 The fclose function returns the numeric value of errno if
26 there had been an error using the file, or the null value if
29 Closing a closed file is permitted. Fclose returns null in
33 > fd = fopen("/etc/motd", "r")
34 > if (fd) print "file is open";
38 > if (isnull(err)) print "close successful"; else errno(err);
41 > if (!fd) print "file is closed";
45 fd != files(0) && fd != files(1) && fd != files(2)
51 errno, fclose, feof, ferror, fflush, fgetc, fgetline, fgets, files, fopen,
52 fprintf, fputc, fputs, fseek, fsize, ftell, isfile, printf, prompt