[GSoC] Header Generation for C/C++

Eduard Staniloiu edi33416 at gmail.com
Wed Jul 17 18:51:44 UTC 2019


On Wednesday, 17 July 2019 at 18:00:38 UTC, Manu wrote:
> On Wed, Jul 17, 2019 at 7:29 AM Iain Buclaw via Digitalmars-d 
> <digitalmars-d at puremagic.com> wrote:
>>
>> On Wed, 17 Jul 2019 at 15:40, Eduard Staniloiu via 
>> Digitalmars-d <digitalmars-d at puremagic.com> wrote:
>> >
>> >
>> > I have the following question: Can we use C++11 or would 
>> > that break GDC / LDC? With C++11 we could use `enum class` 
>> > which would solve this nicely. The issue with `enum class` 
>> > is that it will break code since not the fields need to be 
>> > prefixed with the enum name.
>> >
>> > But still, what do you think? What are the pros and cons of 
>> > supporting/using C++11?
>> >
>>
>> No you cannot use C++11, yes it will break GDC bootstrap.
>
> This needs to be optional. I can't NOT use C++11 for 
> instance... We could read the --extern-std flag to drive the 
> output perhaps?

We could use `#if __cplusplus < 201103L` to emit for C++98 and 
C++11, but I was hoping we could avoid that.

I guess it will come to inserting a bunch of `#if`s


More information about the Digitalmars-d mailing list