fix(ohos): restore ohos cfg gate on set_danmaku_config - #68
Merged
Conversation
`erika_presenter_set_danmaku_config` was gated on macos/ios/windows/android while its no-op stub was gated on `not(any(..., target_env = "ohos"))`, so the OpenHarmony target got neither definition and `erika_presenter_set_danmaku_config_ptr` failed to resolve it. The upscaler test lost the same predicate. Both gates came in through PR #58, whose branch predated OpenHarmony support. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
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.
maincurrently fails theOpenHarmony native (arm64)job (see run on 204cdd7).In
crates/erika_capi/src/lib.rsevery platform API is a pair: the real implementation under#[cfg(any(macos, ios, windows, android, target_env = "ohos"))]and a no-op stub under#[cfg(not(any(...same five...)))]. The two lists have to be exact complements — OpenHarmony reportstarget_os = "linux", sotarget_env = "ohos"is the only predicate that matches it.Two gates lost that predicate:
erika_presenter_set_danmaku_config— implementation gated on four targets, stub gated onnot(any(five)), so OpenHarmony got neither definition anderika_presenter_set_danmaku_config_ptrfailed to resolve it (E0425).c_presenter_set_upscaler_accepts_valid_handle— same predicate missing on the test.Both came in through #58, whose branch predated OpenHarmony support; the merge kept the branch side of those hunks.
This restores the predicate on both. No behaviour change on any other target.
Note on #56 and #67
Those two PRs fail the same job for the same reason and are not fixed by this PR — they carry their own dropped predicates (9 and 19 gates respectively, including
luma_upscaler_mode_from_c, theSubtitleStyleConfigimport, theerika_presenter_get_upscaler_statusstub, and the whole new subtitle/memory-font API surface). They will need the same treatment after rebasing on this.Verification
cargo check -p erika_capi --all-targetscargo fmt --all -- --checkerika_capi: every list mentioningandroidalso mentionstarget_env = "ohos", and every impl/stub pair now has identical predicate sets.🤖 Generated with Claude Code