dualfroz ae63f3a6f0 fix: assign target in SignalError.As instead of only checking its type
errors.As calls SignalError.As when it cannot match the concrete type
directly, e.g. for `var target SignalError; errors.As(err, &target)`.
The previous implementation matched target's type and returned true
but never wrote to it, so callers got a successful errors.As result
with a zero-valued SignalError and no indication the signal was lost.

Add a regression test asserting the target is actually populated.
2026-09-04 06:21:22 +02:00
S
Description
My contributions to oklog/run: 2 commits
32 KiB
0 Stars 1 Watchers 0 Forks
Languages
Go 100%