built in import c header files
12345swordy
alexanderheistermann at gmail.com
Sun Apr 18 00:01:14 UTC 2021
On Saturday, 17 April 2021 at 23:22:47 UTC, Max Haughton wrote:
> On Saturday, 17 April 2021 at 22:12:41 UTC, 12345swordy wrote:
>> On Saturday, 17 April 2021 at 21:32:24 UTC, Walter Bright
>> wrote:
>>> On 10/6/2020 7:56 PM, Max Haughton wrote:
>>>> Not impossible (it's worth saying that you can literally do
>>>> this as a library via mixins), but having a c parser in the
>>>> compiler seems like too much work when it's already fairly
>>>> trivial to do. If D had a team of full time staff on
>>>> payroll, then it could be made to work but it adds so much
>>>> surface area to the compiler.
>>>
>>> You'll also have problems with all the nutburger C extensions
>>> implemented by various compilers.
>>
>> There is no need for the dmd frontend to implement that. The
>> ldc2 and the gdc compilers can relay on their c++ counterparts
>> to provided the c extensions.
>>
>> -Alex
>
> No they can't or at least GCC *maybe* could but LDC is a
> separate project entirely from clang.
Actually they can. It is a question of money/time/resources not
programming ability here.
Regardless the dmd front-end just need to strictly implement the
c99 standard(no language extension by the compiler of any sorts)
to get the ball rolling.
-Alex
More information about the Digitalmars-d
mailing list