[PR #3974] [MERGED] fix(managed): verify Mach-O ABI-prefixed exports exactly #5977

Closed
opened 2026-10-31 01:10:54 +00:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/morluto/rea/pull/3974
Author: @Hahaa909
Created: 10/15/2026
Status: ✅ Merged
Merged: 10/16/2026
Merged by: @morluto

Base: main ← Head: jianghh/rea-3961-mach-o-abi-export


📝 Commits (1)

  • b0f8f19 fix(managed): verify Mach-O ABI-prefixed exports exactly

📊 Changes

2 files changed (+21 additions, -5 deletions)

View changed files

📝 src/domain/managed/managedNativeVerificationMatch.ts (+7 -5)
📝 tests/conformance/providers/managed/managedNativeVerification.test.ts (+14 -0)

📄 Description

Summary

Fixes #3961.

A Mach-O export table represents external C symbols with a leading ABI underscore. The managed/native verifier already used that normalized spelling to collect candidates, but its exact-match classification compared the declaration with the raw export spelling. As a result, a declared open_native import matched _open_native only as an inferred decorated candidate.

This change reuses one Mach-O-aware symbol-name normalization for both candidate discovery and exact-match classification. The original export spelling remains in the evidence, while the declaration is reported as an observed exact export match.

Validation

  • npm run test:focused -- tests/conformance/providers/managed/managedNativeVerification.test.ts
  • npm run check:fast
  • git diff --check

The regression test covers open_native with a Mach-O _open_native export and preserves the existing guard that an explicitly underscored managed declaration is not treated as the same name.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/morluto/rea/pull/3974 **Author:** [@Hahaa909](https://github.com/Hahaa909) **Created:** 10/15/2026 **Status:** ✅ Merged **Merged:** 10/16/2026 **Merged by:** [@morluto](https://github.com/morluto) **Base:** `main` ← **Head:** `jianghh/rea-3961-mach-o-abi-export` --- ### 📝 Commits (1) - [`b0f8f19`](https://github.com/morluto/rea/commit/b0f8f19e3b0fbac3c167621587eb21d6d789e034) fix(managed): verify Mach-O ABI-prefixed exports exactly ### 📊 Changes **2 files changed** (+21 additions, -5 deletions) <details> <summary>View changed files</summary> 📝 `src/domain/managed/managedNativeVerificationMatch.ts` (+7 -5) 📝 `tests/conformance/providers/managed/managedNativeVerification.test.ts` (+14 -0) </details> ### 📄 Description ## Summary Fixes #3961. A Mach-O export table represents external C symbols with a leading ABI underscore. The managed/native verifier already used that normalized spelling to collect candidates, but its exact-match classification compared the declaration with the raw export spelling. As a result, a declared `open_native` import matched `_open_native` only as an inferred decorated candidate. This change reuses one Mach-O-aware symbol-name normalization for both candidate discovery and exact-match classification. The original export spelling remains in the evidence, while the declaration is reported as an observed exact export match. ## Validation - `npm run test:focused -- tests/conformance/providers/managed/managedNativeVerification.test.ts` - `npm run check:fast` - `git diff --check` The regression test covers `open_native` with a Mach-O `_open_native` export and preserves the existing guard that an explicitly underscored managed declaration is not treated as the same name. <!-- Author readiness declarations intentionally left unchecked for human review. --> --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-10-31 01:10:54 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
morluto/rea#5977
No description provided.