Skip to content

Update macro conditions for runtime usage - #257

Merged
kateinoigakukun merged 3 commits into
swiftwasm:mainfrom
GoodNotes:fixRuntimeMacro
Jul 31, 2024
Merged

Update macro conditions for runtime usage#257
kateinoigakukun merged 3 commits into
swiftwasm:mainfrom
GoodNotes:fixRuntimeMacro

Conversation

@fjtrujy

@fjtrujy fjtrujy commented Jul 30, 2024

Copy link
Copy Markdown
Contributor

_runtime(_multithreaded) is available only in the main snapshot toolchain, but unavailable in 6.0. However, we cannot distinguish them because compiler(>=6.1) is still false in the main snapshot toolchain. Thus add hasFeature(IsolatedAny2) condition, which is only available in main snapshot toolchains.

Comment thread Sources/JavaScriptEventLoop/JavaScriptEventLoop.swift Outdated
Comment thread Sources/JavaScriptEventLoop/WebWorkerTaskExecutor.swift Outdated
Comment thread Tests/JavaScriptEventLoopTests/WebWorkerTaskExecutorTests.swift Outdated
kateinoigakukun and others added 2 commits July 30, 2024 19:50
The main toolchain still says it's 6.0, so we can' distinguish them by `#if compiler`.
The feature is baseline in the main branch but not in the 6.0, so we can use it for now.
@kateinoigakukun
kateinoigakukun merged commit abc05a9 into swiftwasm:main Jul 31, 2024
@fjtrujy
fjtrujy deleted the fixRuntimeMacro branch October 24, 2025 11:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants