enumstd.c.darwin.EXC[src]

Container Types

Fields

NULL = 0
BAD_ACCESS = 1

Could not access memory

BAD_INSTRUCTION = 2

Instruction failed

ARITHMETIC = 3

Arithmetic exception

EMULATION = 4

Emulation instruction

SOFTWARE = 5

Software generated exception

BREAKPOINT = 6

Trace, breakpoint, etc.

SYSCALL = 7

System calls.

MACH_SYSCALL = 8

Mach system calls.

RPC_ALERT = 9

RPC alert

CRASH = 10

Abnormal process exit

RESOURCE = 11

Hit resource consumption limit

GUARD = 12

Violated guarded resource protections

CORPSE_NOTIFY = 13

Abnormal process exited to corpse state

Values

ConstantTYPES_COUNT[src]

Source Code

Source code
pub const TYPES_COUNT = @typeInfo(EXC).@"enum".fields.len

ConstantSOFT_SIGNAL[src]

Source Code

Source code
pub const SOFT_SIGNAL = 0x10003

Source Code

Source code
pub const EXC = enum(exception_type_t) {
    NULL = 0,
    /// Could not access memory
    BAD_ACCESS = 1,
    /// Instruction failed
    BAD_INSTRUCTION = 2,
    /// Arithmetic exception
    ARITHMETIC = 3,
    /// Emulation instruction
    EMULATION = 4,
    /// Software generated exception
    SOFTWARE = 5,
    /// Trace, breakpoint, etc.
    BREAKPOINT = 6,
    /// System calls.
    SYSCALL = 7,
    /// Mach system calls.
    MACH_SYSCALL = 8,
    /// RPC alert
    RPC_ALERT = 9,
    /// Abnormal process exit
    CRASH = 10,
    /// Hit resource consumption limit
    RESOURCE = 11,
    /// Violated guarded resource protections
    GUARD = 12,
    /// Abnormal process exited to corpse state
    CORPSE_NOTIFY = 13,

    pub const TYPES_COUNT = @typeInfo(EXC).@"enum".fields.len;
    pub const SOFT_SIGNAL = 0x10003;

    pub const MASK = packed struct(u32) {
        _0: u1 = 0,
        BAD_ACCESS: bool = false,
        BAD_INSTRUCTION: bool = false,
        ARITHMETIC: bool = false,
        EMULATION: bool = false,
        SOFTWARE: bool = false,
        BREAKPOINT: bool = false,
        SYSCALL: bool = false,
        MACH_SYSCALL: bool = false,
        RPC_ALERT: bool = false,
        CRASH: bool = false,
        RESOURCE: bool = false,
        GUARD: bool = false,
        CORPSE_NOTIFY: bool = false,
        _14: u18 = 0,

        pub const MACHINE: MASK = @bitCast(@as(u32, 0));

        pub const ALL: MASK = .{
            .BAD_ACCESS = true,
            .BAD_INSTRUCTION = true,
            .ARITHMETIC = true,
            .EMULATION = true,
            .SOFTWARE = true,
            .BREAKPOINT = true,
            .SYSCALL = true,
            .MACH_SYSCALL = true,
            .RPC_ALERT = true,
            .CRASH = true,
            .RESOURCE = true,
            .GUARD = true,
            .CORPSE_NOTIFY = true,
        };
    };
}