Drop extern (C++)
Don
nospam at nospam.com
Wed May 12 22:20:19 PDT 2010
Walter Bright wrote:
> dsimcha wrote:
>> == Quote from Don (nospam at nospam.com)'s article
>>> BLS wrote:
>>>> Hi,
>>>> I think nearly nobody is using extern (C++) 'cause of it's limits. So
>>>> why not drop it ? IMHO this feature is not a " D2 sales argument",
>>>> instead it's vs. productive.
>>>> What do you think ?
>>>> Bjoern
>>>>
>>> There's a much more fundamental problem with it: C++ doesn't support it!
>>> You can't compile a file with MSVC and link it to something compiled
>>> with g++.
>>> Look up my CodeProject article on member function pointers -- every
>>> vendor has their own API, and virtually none of them are documented.
>>> On Windows, extern(C++) means extern(DMC++), but for me, the only thing
>>> I'd want to link to is MSVC. Much more useful would be, as Brad says, to
>>> provide a way of specifying the name mangling. If we could do that, we'd
>>> be more compatible with C++ than C++ is to itself.
>
> There's a lot more to compatibility than name mangling.
Yes, but the language is powerful enough to deal with everything else.
More information about the Digitalmars-d
mailing list