Integers The Objects The empty object

The empty object

The first step in a program of SYMMETRICA is the generation of an object. This newly generated object is always an empty object. This is done in the following program
#include "def.h"
#include "macro.h"
main()
{
OP object;
anfang();
object = callocobject();  /* generation of an object */
freeall(object);          /* deletion of an object */
ende();
}
Using the routine callocobject() you generate an empty object. This object must have been declared using the type OP, which is also defined in "def.h". After all you have to delete the object, this is done using the standard routine freeall(), which works for all objects, not only with empty objects. If you print an empty object you will get a "#", which is the symbol for the empty object. If you change the above code into
...
object = callocobject();    /* generation of an object */
println(object);
freeall(object);            /* deletion of an object */
...
you get the following line

#


harald.fripertinger "at" uni-graz.at, May 26, 2011

Integers The Objects Uni-Graz Mathematik The empty object Valid HTML 4.0 Transitional Valid CSS!