druntime redesign

Denis Feklushkin feklushkin.denis at gmail.com
Tue Mar 17 17:38:41 UTC 2020


On Tuesday, 17 March 2020 at 17:12:39 UTC, IGotD- wrote:
> On Tuesday, 17 March 2020 at 16:25:22 UTC, Johan wrote:
>>
>> Rather than setting the import directory, I think a much nicer 
>> solution is something like this:

Yes, already implemented in new PR: 
https://github.com/dlang/druntime/pull/2997

>> https://github.com/weka-io/mecca/blob/master/src/mecca/platform/os/package.d
>> This works for different OS types, different CPU types, etc. 
>> And it removes the need to specify a whole list of specific 
>> import directories for each OS/cpu combination in the config 
>> file (please keep LDC crosscompilation in mind).
>>
>> -Johan
>
> How is this different from using version?

I used version (CRuntime_Abstract) to import platform dependent 
code.

This strategy looks good, but again there is a problem that is 
not directly related to the code: changing one module required 
changing only 8 lines in the code, but 15 lines in build scripts. 
And this is not all of needed changes - LDC uses its own cmake 
build scripts.

And each module will require approximately same changes. It will 
be like a disaster. Thus, at first stage we need to clear up 
build scripts.



More information about the Digitalmars-d mailing list