On macOS one Mach-O slice can contain multiple load commands: One load command for being loaded into a macOS process and one load command for being loaded into a macCatalyst process. This patch adds support for the new load command and makes sure ObjectFileMachO returns the Architecture that matches the Module.
|1111 ↗||(On Diff #216744)|
'required' here sounds weird as we're testing against multiple ones. "Matching" maybe?
|1126 ↗||(On Diff #216744)|
|1128 ↗||(On Diff #216744)|
Is MapFileData guaranteed to succeed? (ie return a valid data_sp)
|4976 ↗||(On Diff #216744)|
can this be a const ref to make it clear it's not an output parameter?
|4977 ↗||(On Diff #216744)|
Can ModuleSpecList be moved efficiently? If so, could we return it with NRVO rather than using an output param?
|5060 ↗||(On Diff #216744)|
Can we merge this loop with the above one? Are there binaries with both LC_VERSION_MIN and LC_BUILD_VERSION? If so merging would give different results.
|5072–5073 ↗||(On Diff #216744)|
Does struct build_version_command have exactly the same size on every platform? Even if that's true, it seems like it would be more principled to extract each field in turn.