From 7ada18f9616d29ba5737fa8df978a7b8d27cf39a Mon Sep 17 00:00:00 2001 From: treeform Date: Wed, 9 Sep 2026 07:04:40 -0700 Subject: [PATCH 1/2] Let Windy own loadExtensions and build the CPU backend in CI Silky defined its own no-op loadExtensions for the Metal and CPU backends. Windy already exports one on Win32 for DirectX, Vulkan and CPU, so on Windows CPU builds both were visible and every loadExtensions() call in the examples was ambiguous: Error: ambiguous call; both platform.loadExtensions() and silky.loadExtensions() match for: () That broke all eight examples with -d:useCpu on Nim 2.2.10 and 2.2.12. CI never noticed because the CPU backend was not in the matrix. Silky already does `export windy`, so dropping the local copy leaves callers with Windy's symbol and nothing else. Windy is gaining the matching no-op on macOS for Metal and CPU (treeform/windy PR), and the lock file should move to that Windy once it lands. Add a Windows CPU cell to the CI matrix and run the existing CPU smoke test in every cell so this stays fixed. The test is a no-op unless -d:useCpu is set on Windows. Co-Authored-By: Claude Fable 5.1 --- .github/workflows/build.yml | 4 ++++ src/silky.nim | 5 ----- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 67f33f6..a5c735a 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -20,6 +20,9 @@ jobs: - os: windows-latest name: Windows Vulkan build_flags: "-d:useVulkan" + - os: windows-latest + name: Windows CPU + build_flags: "-d:useCpu" - os: ubuntu-latest name: Linux OpenGL build_flags: "" @@ -59,6 +62,7 @@ jobs: nim r -d:silkyTesting tests/test_layout.nim nim r -d:silkyTesting tests/test_layout_regressions.nim nim r ${{ matrix.build_flags }} tests/test_layout_clips.nim + nim r ${{ matrix.build_flags }} tests/test_cpu_backend.nim - name: Compile examples if: ${{ !matrix.emscripten }} diff --git a/src/silky.nim b/src/silky.nim index 7349d69..64b0ec8 100644 --- a/src/silky.nim +++ b/src/silky.nim @@ -23,8 +23,3 @@ else: export widgets except button, checkBox, clickableIcon, dropDown, frame, group, h1text, icon, iconButton, image, listBox, progressBar, radioButton, ribbon, scrubber, text - - when defined(useMetal4) or defined(useCpu): - proc loadExtensions*() {.inline.} = - ## No-op helper for non-OpenGL backends. - discard From 16c0310243aaa339103514ba87b15c4dda0b865e Mon Sep 17 00:00:00 2001 From: treeform Date: Wed, 9 Sep 2026 07:13:22 -0700 Subject: [PATCH 2/2] Lock Windy at the commit that exports loadExtensions on macOS treeform/windy#195 is merged, so the macOS Metal and CPU backends get their no-op loadExtensions from Windy and the previous commit's removal of Silky's copy no longer leaves macOS without one. Co-Authored-By: Claude Fable 5.1 --- nimby.lock | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nimby.lock b/nimby.lock index 2ccf14d..fea1329 100644 --- a/nimby.lock +++ b/nimby.lock @@ -8,7 +8,7 @@ nimsimd 1.3.2 https://github.com/guzba/nimsimd 3f6b2668ffb0867d0bf786a658b817763 bumpy 1.1.3 https://github.com/treeform/bumpy dc9a3d6d15680ec7f603959d65ba8ee4f1ddbc72 crunchy 0.1.11 https://github.com/guzba/crunchy 98eb6526982bb8aae8eec6e8781f4539fa19e049 bitty 0.1.4 https://github.com/treeform/bitty/ c40e81277c04befa37234cba5052f58648bef895 -windy 0.4.4 https://github.com/treeform/windy 4221e9b19b701986889134fea963c6b0191186a7 +windy 0.5.0 https://github.com/treeform/windy 5971abb08f416cfb8a3603a3093503eb07f2f5c4 opengl 1.2.9 https://github.com/nim-lang/opengl 8e2e098f82dc5eefd874488c37b5830233cd18f4 urlly 1.1.1 https://github.com/treeform/urlly 99784779f05649df25fd9c33003d8ef6de027345 ws 0.5.0 https://github.com/treeform/ws cbb8f763b436669392d10baec2a45778395395cc