News for hackers. Stuff that matters.
Re:Koto Programming Language by zozbot234 on Saturday March 29, 2025 @11:38AM (#43516356)
Rust will probably gain support for "pluggable" and optional garbage collectors as part of its upcoming local allocators API. This will ultimately give devs the best of both choices - use tracing GC where it's actually needed (because you're working with totally general graph-like data and that's the only feasible memory management strategy) and manual memory management (supplemented by RAII and reference counting) elsewhere - for other parts of the program that don't have to manage general "spaghetti" graphs. Unfortunately the way GC's trace memory and collect garbage varies widely among implementations, so there's no easy way to standardize a "generic" interface to pluggable garbage collection. that all custom crates can be expected to tap into by default. But other uses should be quite feasible.
Re:Koto Programming Language by SkiFire13 on Saturday March 29, 2025 @02:10PM (#43517367)
> Rust will probably gain support for "pluggable" and optional garbage collectors as part of its upcoming local allocators API.

Source? AFAIK there's no confirmed upcoming allocators APIs, and even if there was they would just allow reusing the builtin `Box`/`Vec`/etc etc with custom allocators. This is not much different than what you could do with a custom type, so I find it hard to believe it would allow garbage collectors that are not possible right now.