function endmodule(&p)