# HandleableSignalValidator
<span class="source-link">[[Source]](src/signals/handleable_signal.md#L-0-3)</span>

Validates that a signal number is handleable via the ASIO mechanism.

Only signals that can be safely caught and dispatched to Pony actors
are accepted. Fatal signals (SIGILL, SIGTRAP, SIGABRT, SIGFPE, SIGBUS,
SIGSEGV), uncatchable signals (SIGKILL, SIGSTOP), and unknown signal
numbers are rejected. SIGUSR2 is accepted only on
scheduler_scaling_pthreads builds; on other builds the runtime reserves
it for scheduler sleep/wake and `Sig.usr2()` is a compile error.

Validation is necessary but not sufficient: the operating system can
still refuse a registration the whitelist admits (for example, glibc
reserves the two lowest real-time signals for its own threading
internals, and musl the three lowest). Such a refusal surfaces through
the normal failure path — the notify's `registration_failed` is called
and the handler is automatically disposed.
Diagnostic runtime builds (`use=runtime_tracing`) additionally reserve a
pause signal — SIGRTMIN on Linux, SIGINFO on BSD and macOS — and
handling that signal in such a build breaks runtime tracing.


```pony
primitive val HandleableSignalValidator is
  Validator[U32 val] val
```

#### Implements

* [Validator](constrained_types-Validator.md)\[[U32](builtin-U32.md) val\] val

---

## Constructors

### create
<span class="source-link">[[Source]](src/signals/handleable_signal.md#L-0-3)</span>


```pony
new val create()
: HandleableSignalValidator val^
```

#### Returns

* [HandleableSignalValidator](signals-HandleableSignalValidator.md) val^

---

## Public Functions

### apply
<span class="source-link">[[Source]](src/signals/handleable_signal.md#L-0-24)</span>


Return `ValidationSuccess` for a handleable signal number, or a
`ValidationFailure` naming the rejected number.


```pony
fun box apply(
  sig: U32 val)
: ValidationResult
```
#### Parameters

*   sig: [U32](builtin-U32.md) val

#### Returns

* [ValidationResult](constrained_types-ValidationResult.md)

---

### eq
<span class="source-link">[[Source]](src/signals/handleable_signal.md#L-0-24)</span>


```pony
fun box eq(
  that: HandleableSignalValidator val)
: Bool val
```
#### Parameters

*   that: [HandleableSignalValidator](signals-HandleableSignalValidator.md) val

#### Returns

* [Bool](builtin-Bool.md) val

---

### ne
<span class="source-link">[[Source]](src/signals/handleable_signal.md#L-0-24)</span>


```pony
fun box ne(
  that: HandleableSignalValidator val)
: Bool val
```
#### Parameters

*   that: [HandleableSignalValidator](signals-HandleableSignalValidator.md) val

#### Returns

* [Bool](builtin-Bool.md) val

---

