镜像站点 · 本页由第三方 GitHub 只读镜像提供,非 GitHub 官方站点,不接受任何登录或凭据输入。前往 github.com
Skip to content

ABI: implement retired module-registry snapshot shims exactly #402

Closed

Description

@chrisbbreuer

Parent: #140
Profiles: #163, #164
Roadmap: #134

Pinned Bun 4982b91e retains two module-registry snapshot symbols as dead ABI compatibility shims after JSC stopped exposing the loader registry as a JavaScript Map. Implement their documented current behavior exactly instead of inventing a snapshot format.

Scope

  • Pin ZigGlobalObject.cpp source identity and its explicit no-caller contract.
  • Export Zig__GlobalObject__getModuleRegistryMap as nullptr.
  • Export Zig__GlobalObject__resetModuleRegistryMap as false.
  • Prove globals, opaque pointers, module state, and pending exceptions are not inspected or mutated.
  • Compile, link, and run Home and Bun profile consumers in Debug and ReleaseSafe.
  • Refresh inventories, concise README counts, and parent evidence.
  • Close only on green fixing CI.

This is deliberately exact: pinned upstream says the loader registry is no longer a JS Map, snapshot/restore is unsupported, both symbols have no callers, and they remain only for ABI compatibility.

Activity

  1. chrisbbreuer commented on Jul 20, 2026

    @chrisbbreuer
    MemberAuthor

    Implemented and pushed to main in 540888cf + 737bd957. Both pinned symbols match upstream’s explicit dead-shim behavior (nullptr / false) without argument or VM inspection. Focused unit and dual-profile external consumers pass in Debug and ReleaseSafe; both audits, compatibility, and the 32-page docs build pass. Published counts are Home 427/471 (44 pending) and Bun 418/461 (43 pending). Awaiting green fixing CI before closure.

  2. chrisbbreuer commented on Jul 20, 2026

    @chrisbbreuer
    MemberAuthor

    Closure gate is green: the exact private-abi-boundary job for main commit 7983fcab completed successfully: https://github.com/zig-utils/zig-js/actions/runs/29776746300/job/88467854285

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions