ImportC and nothrow/@nogc?

jmh530 john.michael.hall at gmail.com
Fri Aug 30 14:14:22 UTC 2024


On Friday, 30 August 2024 at 10:20:07 UTC, Atila Neves wrote:
> On Thursday, 29 August 2024 at 19:50:10 UTC, Steven 
> Schveighoffer wrote:
>
> [snip]
>
> Except you can't, because it's a C file, not D. What am I 
> missing?

There was a lot of back and forth last year about having importC 
recognize .h files.

Initial bug report here: 
https://issues.dlang.org/show_bug.cgi?id=23479
PRs about it: https://github.com/dlang/dmd/pulls?q=is%3Apr+23479+

The result is that if there is some C header that you want to 
use, you have to make a .c file to include it and then import 
that with importC.



More information about the Digitalmars-d mailing list