On Sun, 17 Dec 2023, Adriaan van Os via fpc-pascal wrote:


Michael Van Canneyt via fpc-pascal wrote:


On Sat, 16 Dec 2023, Adriaan van Os via fpc-pascal wrote:


More questions about the FreePascal Language Reference (version 3.2.0), part 4

34. Are macpas LEAVE and CYCLE statements undocumented ?

Yes.

Well, according to Appendix D.6 of the Programmer's Manual, CYCLE is equivalent to CONTINUE and LEAVE to BREAK. Contrary to the information presented there, the CYCLE and LEAVE statements have been implemented for macpas mode.

I don't see BREAK and CONTINUE in the syntax diagrams either. I put together some examples (stressing that I am not a proponent of these C constructs).

That is because "break" and "continue" as well as leave are not keywords: you can use them as identifiers.

As such they are considered normal procedure calls and are documented in the 
system unit.

That explains why they're not in the syntax diagrams: when they appear, they are
treated as procedure calls.

Michael.
_______________________________________________
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
https://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Reply via email to