Known Limitations
Wyn is honest about what works and what doesn't. This page is kept up to date.
Design Decisions
- Coroutine stack size — defaults to 8MB virtual (only ~0.3KB physical per coroutine). Configurable via
WYN_CORO_STACK. Crash messages show whichspawncreated the coroutine. - Variable shadowing —
var x = 1; var x = 2is a compile error. Use different names. - HashMap.keys()/values() — return comma-separated strings. Use
.split(",")for an array. wyn check— Compile-time type checker. Catches undefined variables/functions, type mismatches, wrong argument counts, const reassignment, missing returns, unused variables, unreachable code. Some stdlib return types default tointwhen unrecognized — use explicit type annotations.string.len()returns bytes — UTF-8 byte count, not character count."🐉".len()is 4.- Division by zero — returns 0 (C behavior). Use
Math.checked_add/sub/mulfor safe arithmetic, or Result type for safe division. - Integer overflow — silent by default. Use
Math.checked_add(),Math.checked_sub(),Math.checked_mul()for overflow detection.
Not Yet Implemented
- Tuple types —
fn divmod(a, b) -> (int, int)is not yet supported. Use structs instead. - Named arguments —
connect(host: "localhost", port: 8080)is not yet supported. Use positional arguments with default parameters:fn connect(host: string = "localhost", port: int = 8080). - Generic structs —
struct Stack<T>is not yet supported. Generic functions work. - Trait bounds —
fn sort<T: Comparable>(arr: Array<T>)is not yet supported. selectsyntax — useTask.select_2(ch1, ch2)API instead.
Platform Notes
- Windows regex — Uses built-in NFA engine. Supports ERE syntax (
.,[],^$,*+?,(),|,\d\w\s). No backreferences or lookahead. - Audio — requires SDL2_mixer. Stubs when absent.
- Mobile —
system()/popen()return stubs on iOS/Android. - TCC backend — bundled for macOS ARM64. Other platforms use system
gcc/clang. - HTTPS — uses
openssl s_clientvia shell. Works on macOS/Linux where OpenSSL is available.