January 25, 2012
As http://d.puremagic.com/issues/show_bug.cgi?id=4788 points out, extern(System) isn't properly documented, so I have no idea what it translates to. Does anyone know what exactly it translates to on Linux/Posix and Windows?

- Jonathan M Davis
January 25, 2012
On 01/25/2012 05:39 AM, Jonathan M Davis wrote:
> As http://d.puremagic.com/issues/show_bug.cgi?id=4788 points out,
> extern(System) isn't properly documented, so I have no idea what it translates
> to. Does anyone know what exactly it translates to on Linux/Posix and Windows?
>
> - Jonathan M Davis

extern(Windows) on windows and extern(C) on everything else.

-- 
Mike Wey
January 25, 2012
I was pretty sure it's somewhere in the spec.
January 25, 2012
On Wednesday, January 25, 2012 22:31:19 Mike Wey wrote:
> On 01/25/2012 05:39 AM, Jonathan M Davis wrote:
> > As http://d.puremagic.com/issues/show_bug.cgi?id=4788 points out, extern(System) isn't properly documented, so I have no idea what it translates to. Does anyone know what exactly it translates to on Linux/Posix and Windows?
> > 
> > - Jonathan M Davis
> 
> extern(Windows) on windows and extern(C) on everything else.

But it doesn't include export in with the extern(Windows)?

- Jonathan M Davis
January 25, 2012
On Wednesday, January 25, 2012 23:18:04 Trass3r wrote:
> I was pretty sure it's somewhere in the spec.

I can't find it searching for it or grepping for it.

- Jonathan M Davis
January 26, 2012
"Jonathan M Davis" <jmdavisProg@gmx.com> wrote in message news:mailman.11.1327521278.25230.digitalmars-d-learn@puremagic.com...
> As http://d.puremagic.com/issues/show_bug.cgi?id=4788 points out,
> extern(System) isn't properly documented, so I have no idea what it
> translates
> to. Does anyone know what exactly it translates to on Linux/Posix and
> Windows?

It should be on http://www.d-programming-language.org/attribute.html in the 'Linkage Attribute' section, but naturally it's only mentioned.

But at least I can tell you in the compiler, the definition is simple:

        else if (id == Id::System)
        {
#if _WIN32
            link = LINKwindows;
#else
            link = LINKc;
#endif
        }


Top | Discussion index | About this forum | D home