Exit v0.1.0

Source
Terminates the process immediately.

Package: MacOS

Signature

func Exit(code: int32);

Parameters

NameTypeDescription
codeint32Status reported to the process's parent.

Description

Exit invokes the low-level target macOS exit operation. It does not return, unwind the stack, flush user-space buffers, or run cleanup code. A waiting parent normally observes only the low 8 bits of the status.

Prefer returning from Main for normal termination. Use Exit only when the process must stop immediately.

See also

  • MacOS — the package overview