DMD Refuses to Compile Multiple Source Files
Samwise via Digitalmars-d-learn
digitalmars-d-learn at puremagic.com
Tue Jan 17 20:06:23 PST 2017
On Wednesday, 18 January 2017 at 03:51:50 UTC, ketmar wrote:
> On Wednesday, 18 January 2017 at 03:37:46 UTC, Samwise wrote:
>> extern int getReturnCode() {
>> return 4;
>> }
>>
>> still does not compile using the command from above. I may
>> very well be misunderstanding you though.
>
> yep. *both* prototype and real declaration should be
> `extern(C)`. `(C)` part is important too!
I have both the header in hello.d and the actual function in
getReturnCode.d as extern, and it still fails with the same error.
More information about the Digitalmars-d-learn
mailing list