Repository navigation
iOS release builds compile again: dismiss_keyboard leaves the debug-only block (MOB-504) - #229
Merged
Merged
Conversation
…nly block (MOB-504) mob 0.9.26 defined nif_dismiss_keyboard and find_first_responder_in inside the test harness's #if !MOB_RELEASE block while the nif_funcs entries for dismiss_keyboard/0,1 sat outside it, so every iOS release build failed with 'use of undeclared identifier'. Both functions now sit above the harness block. test/native/ios_nif_compile.sh (make -C test/native ios-nif) generates MobApp-Swift.h and syntax-compiles ios/mob_nif.m as debug, release, and release with MOB_ENABLE_SCREENSHOT; CI's macOS job runs it. It fails on the 0.9.26 source and passes with this fix.
….9.27 gate) mob_dev sends :__mob_hot_reload__ as a bare message to :mob_screen, which names one window's router; further windows kept drawing the old code until their next render. The router now handles the message itself: it repaints its own screens and casts the reload to every other router Mob.Scenes lists, from a spawned process so it never waits on Mob.Scenes. Also fixes the Mob.Test moduledoc example: screens/1 reports native's scene id on iOS.
Owner
Author
|
Release gate for 0.9.27, run by a reviewer subagent because Codex is rate-limited until 5:02 AM.
|
Merged
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes MOB-504, which mob_ci's nightly reported.
Bug. In mob 0.9.26,
nif_dismiss_keyboard(from #173) and thefind_first_responder_inhelper it uses were defined inside the test harness's#if !MOB_RELEASEblock (ios/mob_nif.m:5065in 0.9.26). Theirnif_funcsentries were outside it, so every iOS release build failed:#184 added
dismiss_keyboard/1, so master had the same problem twice over.Fix. Both functions move above the harness block. Both use only public UIKit (
isFirstResponder,resignFirstResponder), so nothing App Store-sensitive moves into release builds. No other NIF has this mismatch: I compared every function defined inside aMOB_RELEASEguard with the guard on its table entry, and no non-static function is defined inside a guard.Guard against a repeat.
test/native/ios_nif_compile.sh(make -C test/native ios-nif) generatesMobApp-Swift.hwithswiftc. It then syntax-compilesios/mob_nif.mfor arm64 iOS in three variants: debug, release, and release withMOB_ENABLE_SCREENSHOT. CI's macOS job runs it afterbrew install erlang, which provideserl_nif.h. RELEASE.md lists it as a mob preflight step.Verification.
mob_nif.mwith the error above, in both release variants, and passes on this branch.mix testpasses 2155 (38 excluded).make -C test/native runand clang-format are clean.This goes out as mob 0.9.27.