Should C linkage (aka "extern (C)") be the default when using "betterC"?

the spineless community spineless at dlang.org
Mon Mar 14 00:43:35 UTC 2022


On Saturday, 5 March 2022 at 11:23:05 UTC, rempas wrote:
> Am I the only one that things this way? If I'm not wrong, other 
> than some (mostly runtime) advantages that "betterC" offers, It 
> is also necessary when someone wants to allow their library to 
> generate binding for other languages.
>
> So I would say that not having to type "extern(C):" in the top 
> of every file, would be great. Another things we could have is 
> a compiler switch to choose the default linkage we want. Unless 
> this is possible and I just not know it...

No, why a C linkage?

D should stay neutral.

It does not even has a spine (nor it desires any), why a C 
linkage?


More information about the Digitalmars-d mailing list