Files
moonwell-client-core/crates
Berchia 0e5c47bc79 Disjoint sets box their state, so a system holding the host is small (#3045)
A `disjoint_set!` held every member's state inline, and `ScriptCallHost`'s is 181 KB. Bevy keeps a system's param state inline from the moment the system is made, so every system that takes the host was 181 KB or more on the stack while a plugin added it. Building the headless client came close to a Linux test thread's 2 MB, and any change near those systems could overflow `the_hosted_vm_keeps_one_state_across_calls`.

The set's state is now boxed; nothing outside the macro changes. A test holds the host's state to at most 64 bytes. On Windows, that test's stack need drops from about 1.5 MB to about 400 KB.

🤖 Generated with [Claude Code](https://claude.com/claude-code)
2026-11-22 06:47:39 +07:00
..