What are (were) the most difficult parts of D?
eugene
dee0xeed at gmail.com
Sat May 21 11:20:25 UTC 2022
On Tuesday, 17 May 2022 at 11:50:30 UTC, zjh wrote:
> On Tuesday, 17 May 2022 at 06:28:10 UTC, cc wrote:
>
>> Far better to just keep your house clean every day than let
>> the trash pile up and wait for the maid to come, IMO.
>
> Right,GC is a bad idea!
As I've already mentioned I think the origin of GC is functional
langs,
and the reason to have GC as essential part of a language is
*immutability*,
immutability as a main principle.
Say, we have an array of 10 floats and we want to change 3rd
element.
In truly functional language we can not do that - we must
produce new array in which 3rd element is changed.
Old array is now garbage, i.e. we *naturally* have A LOT of
garbage in
functional langs.
But D as 'C/C++ with GC' still puzzles me.
Of course I know about BetterC, just have not had much time
to try this option.
More information about the Digitalmars-d-learn
mailing list