On Monday, 18 January 2021 at 18:03:12 UTC, IGotD- wrote:
>On Thursday, 14 January 2021 at 17:51:51 UTC, Basile B. wrote:
>This is the last[1] occasion to speak about a programming language initiatly made in D, as the bootstrap phase is very near.
I'd like to thank the D compiler developers, that let me work on DMD even if I borrow another path.
Interesting project.
A few questions.
I see that you use "var auto name" in order to automatically infer the type. Would it be possible just using "var name" for that, similar to other popular languages.
There is currently no information about memory management, is this something you have an idea how to design right now?
It has a memory management system very comparable to older Delphi (<= 2007) or current FreePascal. So dynamic arrays are reference counted and automatically managed when used a local var.
Classes and structures are manually managed but the dtor is automatically called when the instance is a local.
This system is proven to work as the compiler itself is now rewritten in styx.
(example, the valgrind report after running the compiler with the equivalent of D "-unittest" CLI option : https://gitlab.com/styx-lang/styx/-/jobs/1980055910#L110.
To be honest I already knew it will work before implementing ref counting. This has been used for something like 30 years by hundreds and hundreds of programmers.