<div dir="ltr"><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Wed, 28 Aug 2024 at 08:12, Walter Bright via Digitalmars-d <<a href="mailto:digitalmars-d@puremagic.com">digitalmars-d@puremagic.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">On 8/26/2024 10:54 PM, Manu wrote:<br>
> The whole point of ImportC, is to use the API.<br>
<br>
Initially, yes. But the mission creep has already happened, and why not?<br></blockquote><div><br></div><div>Where has it happened? The mission isn't even off the ground. I thought I'd have a go, and it's a complete non-starter.</div><div>So no, I really just want to use the C API; it's called ImportC; surely that's _literally the point_.</div><div></div><div><br></div><div><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
> And if someone does a binary-back-door... who cares? That's called a BUG. <br>
> They're playing with fire already! C doesn't have any such type safety, and they <br>
> shouldn't expect it to.<br>
> They know what they did; they did it intentionally, surely knew what the risk <br>
> factors were, and they are naturally expected to not write such bugs into their <br>
> program.<br>
<br>
The author of the C code likely has no idea that the caller from D exists let <br>
alone that it would require that the C code not call any D functions.<br></blockquote><div><br></div><div>The author of the library expects you to use the library via the API they provide... their API is C code; if C code is nothrow @nogc, then the callback you provide is necessarily nothrow and @nogc also.</div><div>I really can't see the fuss here...<br></div></div></div>