Program termination: Difference between revisions

Content deleted Content added
Sonia (talk | contribs)
→‎{{header|Go}}: added more techniques, removed note on error code values as this is not specified for Go.
Added Delphi example
Line 221: Line 221:


What cleanup will be performed varies. Some implementations have at-exit hooks. SBCL will unwind the stack and execute any <code>unwind-protect</code>s (like <code>finally</code> in other languages) it encounters, unless <code>:recklessly-p t</code> is specified.
What cleanup will be performed varies. Some implementations have at-exit hooks. SBCL will unwind the stack and execute any <code>unwind-protect</code>s (like <code>finally</code> in other languages) it encounters, unless <code>:recklessly-p t</code> is specified.

=={{header|Delphi}}==
<lang Delphi>System.Halt;</lang>

or

<lang Delphi>System.Halt(1); // Optional exit code</lang>


=={{header|E}}==
=={{header|E}}==