Saves all predicates in PredSpecs in PO format to File.
A predicate specification, or a list of such.
A file specification, ‘.po’ extension optional.
save_predicates/2 saves the current definitions of all the
predicates specified by the list of predicate specifications in
PO format into a file. The module of the predicates saved in
the PO file is fixed, so it is not possible to save a
predicate from any module
foo, and reload it into module
bar. Source file information and embedded directives
are not saved. A typical use of this would be to take a snapshot of
a table of dynamic facts.
The PO file that is written out can be loaded using
Please note: if PredSpecs contains specifications for which no matching predicate can be found, a warning is issued, and the file is written anyway. Also, no built-in predicates are saved.