Skip to content

Fix relative list regressions - #37

Merged
p-x9 merged 3 commits into
mainfrom
feature/fix-relative-list-regressions
Aug 7, 2026
Merged

Fix relative list regressions#37
p-x9 merged 3 commits into
mainfrom
feature/fix-relative-list-regressions

Conversation

@p-x9

@p-x9 p-x9 commented Aug 5, 2026

Copy link
Copy Markdown
Owner

Summary

  • require MachOKit 0.52.2, which fixes the remaining Objective-C metadata omission in MachOKit
  • remove the local symbol(...) compatibility extension now provided by MachOKit
  • resolve relative list offsets against the cache that actually backs the target Mach-O
  • preserve every relative-list entry matching an image index instead of returning only the first entry
  • aggregate all matching method, property, and protocol lists in both MachOFile and MachOImage paths
  • add a regression test covering multiple relative method lists for _UTCoreType

Root cause

The cache lookup introduced with the relative-list implementation conflated the cache containing the resolved Mach-O with the cache backing the list data. Separately, the image-index lookup selected only the first matching relative-list entry, while the pre-0.8 implementation combined all matching lists.

This caused Objective-C metadata to be partially omitted when a class had multiple relative lists or when the Mach-O and list data were located in different dyld cache files. MachOKit 0.52.1 also retained a related omission bug, so this package now requires 0.52.2.

Impact

Callers of classInfo(in:) can once again obtain all matching relative methods, properties, and protocols instead of silently losing later lists.

Validation

  • clean staged-tree test with MachOKit 0.52.2 and remote ObjDump 0.7.0: exit 0
  • swift test: 26 tests, 0 failures
  • dyld shared-cache audit with MachOKit 0.52.2: 2,908 relative-method classes checked, 8 duplicate image-index groups, 0 mismatches
  • git diff --check

@p-x9
p-x9 marked this pull request as ready for review August 5, 2026 19:14
@p-x9
p-x9 merged commit 23af662 into main Aug 7, 2026
2 checks passed
@p-x9
p-x9 deleted the feature/fix-relative-list-regressions branch August 7, 2026 14:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant