next up previous contents
Next: Raw Data Files Up: Standard Files Previous: The ReadLibrary command

The save Command

The save command allows users to send an object stored in memory to an external file in such a format that it can be read back into the Darwin environment with a ReadProgram command. In essence, users can send to disk important parts of a work session that might be particularily long and complicated to repeated thus allowing their sessions to be interrupted with the minimal amount of inconvenience.

> w := 'a text name saved to a file';
> x := [1, 2, 3, 4];
> y := proc()
>   return(noeval(copy(y(args))));
> end;
> z := y('abc', 5.5);
> save('filename', w, x, y, z);
Like the ReadProgram command, filename may be preceded by a path name. The save command can send variables of any built-in type, instances of built-in structured types, and procedures to an external file.

Gaston Gonnet