write, writec,
pretty_write, pretty_writec
write, writec,
pretty_write,
pretty_writec — write an expression to a file.
write (file, s_exp...)
writec (file, s_exp...)
pretty_write (file, s_exp...)
pretty_writec (file, s_exp...)
fileA file pointer to a previously opened file. This may be either a file in the file system, or a string opened for read and write.
s_expAny Gamma or Lisp expression.
Writes the given expressions to the file using the same format as
print. See print for more information.
writec produces the same format as
princ; pretty_write produces
the same format as pretty_print; and
pretty_writec produces the same format as
pretty_printc. Any contents written to the file
before it was opened will be deleted when any of these
write functions are used.
Gamma>fw = open("mywritefile.dat", "w");#<File:"mywritefile.dat">Gamma>write(fw,"This is on \n one line.");tGamma>writec(fw,"This finishes on \n another line.");tGamma>close(fw);tGamma>fr = open("mywritefile.dat", "r", nil);#<File:"mywritefile.dat">Gamma>read_line(fr);"\"This is on \n one line.\"This finishes on "Gamma>read_line(fr);" another line."Gamma>