Skip to main content

WORKER_STACK_SIZE

Constant WORKER_STACK_SIZE 

Source
pub const WORKER_STACK_SIZE: usize = _ /* 16_777_216usize */;
Expand description

Stack size for threads that run analysis, and the registration that lets a bounded parse stay on such a thread.

A process that runs analysis outside ProgrammaticAnalysisContext::install, such as the LSP server, gives its own threads this stack size and registers it at thread start. Worker stack size for analysis thread pools.

Recursive AST extraction and analysis overflow the default Rayon worker stack on deeply nested sources, so every pool that runs analysis work must be built with this size. The CLI and LSP global pools and the programmatic per-call pools share this builder so embedders cannot drift. A thread that runs analysis outside these pools, such as a Tokio blocking thread in a server, needs this size too.