28.06.2013 Views

ISO Pascal reference manual

ISO Pascal reference manual

ISO Pascal reference manual

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

*ERROR 21 -- has been used in its own definition<br />

This error is caused by attempting to use < name > to define itself. Note<br />

that the definition of a record may include a pointer to a record of its own<br />

type.<br />

PROGRAM fail;<br />

CONST fool = -fool; [???]<br />

TYPE t = ARRAY [1..5] OF t; I???)<br />

BEGIN<br />

END.<br />

*ERROR 22 -- has already been defined<br />

This error is caused by attempting to define a procedure or function more<br />

than once in the same block.<br />

PROGRAM fail(output);<br />

PROCEDURE fred; BEGIN<br />

writelm('fred 1');<br />

END;<br />

PROCEDURE fred; BEGIN<br />

writeln('fred 2');<br />

END;<br />

BEGIN<br />

fred;<br />

END.<br />

*ERROR 23 -- has not been declared<br />

< name > has been used either before it has been declared or without any<br />

declaration.<br />

PROGRAM fail;<br />

VAR j : integer;<br />

BEGIN<br />

j := k; [k is unknown)<br />

END.<br />

52 <strong>Pascal</strong> Issue I

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!