1
0
forked from rosa/hakurei

all: apply modernisers

Signed-off-by: Ophestra <cat@gensokyo.uk>
This commit is contained in:
2026-06-08 14:19:11 +09:00
parent 725f2e0ef3
commit f869ff95a1
35 changed files with 146 additions and 141 deletions
+2 -3
View File
@@ -212,11 +212,10 @@ func (r *Report) HandleAccess(errP *error) func() {
*errP = err
}
var runtimeError interface {
if runtimeError, ok := errors.AsType[interface {
Addr() uintptr
runtime.Error
}
if errors.As(*errP, &runtimeError) {
}](*errP); ok {
offset := int(runtimeError.Addr() - uintptr(unsafe.Pointer(unsafe.SliceData(r.data))))
// best effort for fragile uintptr
if offset >= 0 {