Skip to content

bun:ffi: use LoadLibraryExW on Windows so dlopen accepts non-ASCII paths - #33712

Merged
Jarred-Sumner merged 5 commits into
mainfrom
farm/8b8f3a3b/ffi-dlopen-windows-unicode
Jul 8, 2026
Merged

bun:ffi: use LoadLibraryExW on Windows so dlopen accepts non-ASCII paths#33712
Jarred-Sumner merged 5 commits into
mainfrom
farm/8b8f3a3b/ffi-dlopen-windows-unicode

fix test: pass fixture dir via env (bun -e argv layout)

6e114da
Select commit
Loading
Failed to load commit list.
Claude / Claude Code Review completed Jul 8, 2026 in 15m 34s

Code review found 1 important issue

Found 3 candidates, confirmed 1. See review comments for details.

Details

Severity Count
🔴 Important 1
🟡 Nit 0
🟣 Pre-existing 0
Severity File:Line Issue
🔴 Important test/js/bun/ffi/ffi.test.js:672 New non-ASCII dlopen test will fail on Windows ARM64 CI

Annotations

Check failure on line 672 in test/js/bun/ffi/ffi.test.js

See this annotation in the file changed.

@claude claude / Claude Code Review

New non-ASCII dlopen test will fail on Windows ARM64 CI

This test will fail on the Windows ARM64 CI lane: `bun:ffi`'s `dlopen` is gated on `ENABLE_TINYCC` (src/runtime/ffi/ffi_body.rs:1428), and TinyCC is disabled for `windows && arm64` (scripts/build/config.ts:869), so the subprocess will throw before printing anything and `exitCode: 0` won't match. Change the guard to `it.skipIf(!isWindows || isArm64)` — the same convention this file already uses via `isFFIUnavailable` at line 719 and in cc.test.ts / ffi-error-messages.test.ts / ffi-viewSource-non-