// /*--------------------------------------------------------*\ // | Main Program: Checked pointer test: tricky example // \*--------------------------------------------------------*/ ///------------------------------------------------------------- /// Global Context --------------------------------------------- ///------------------------------------------------------------- #include "RESOLVE_Foundation.h" concrete_instance class Node : instantiates Record < Integer, Pointer_C > {}; field_name (Node, 0, Integer, data); field_name (Node, 1, Pointer_C , next); ///------------------------------------------------------------- /// Interface -------------------------------------------------- ///------------------------------------------------------------- program_body main () { object Pointer_C p; New (p); New ((*p)[next]); (*(*p)[next])[next] = p; p = NULL; Report_Storage_Allocation (); }