New competitor to D
Ola Fosheim Grøstad
ola.fosheim.grostad at gmail.com
Wed Jul 20 09:53:41 UTC 2022
On Wednesday, 20 July 2022 at 09:35:14 UTC, Templated Person
wrote:
> - The runtime gets leaner and more configurable, gotta have
> that wasm support.
Yes, I think leaner runtime is on the plan?
Memory management is still a big question mark with no clear
resolution.
> - Modern features such as sum types & pattern matching,
> nullables & tuples in the language (not as libraries).
> - Allocators passed into functions (+ a "garbage collecting
> allocator" like we have now)
This is the tricky bit, this should be thought through from
scratch. None of the current directions can converge on something
that fits well together, but with better move semantics you can
at least implement decent ref-counting schemes where `shared` is
used to good effect. E.g. ref counting of objects that are shared
across execution contexts, ref counted arenas. And what about
local GCs that are dropped in O(1) when the execution context is
pulled down?
Quite a bit of language tuning has to be done to get there. Like,
if you allow the entire GC pool to be dropped, then you need to
distinguish between destructors that manage external resources
from destructors that has no consequences outside the context. So
you need a finalizer scheme or a resource manager scheme to make
arena-like allocation pleasant and performant.
More information about the Digitalmars-d
mailing list