A framework for building native applications using React
Use dispatch_semaphore for eager-main-queue module setup gate
Summary: Replace the `std::mutex` + `std::condition_variable` + `std::shared_ptr<bool>` trio that gates the JS thread on main-queue module construction with a single `dispatch_semaphore_t`. The wait block is invoked exactly once (from `_loadScriptFromSource:`'s `beforeLoad` lambda), so single-shot semaphore semantics fit the contract directly — no condition predicate, no shared state captured by three independent `shared_ptr`s. Net: 12 lines deleted, 1 captured object instead of 3, no behavior change. Changelog: [Internal] Reviewed By: sammy-SC Differential Revision: D105953979 fbshipit-source-id: 149e959d04e8466589798ae38c68059db77ecd8b
P
Pieter De Baets committed
c5afd1a20416fe4c25686a6f5fc764298ce020b5
Parent: d672c96
Committed by meta-codesync[bot] <215208954+meta-codesync[bot]@users.noreply.github.com>
on 5/22/2026, 4:46:18 PM