On Friday, 22 May 2020 at 18:32:59 UTC, Steven Schveighoffer wrote:
So the solution is -- make the compiler be dumb for you? If you are going to incorrectly put @safe on it, I want you to have to do it because YOU made a conscious decision to be careless, not have it done for you because you forgot.

Yea, agreed. If a library works around an extern(C) API by slapping `@safe:` on it, this is a visibly problematic thing to do, and people can file bug reports and patches about it. And we can have well documented warnings about this being a bad way to do things.

If a library just gets extern(C) APIs as @safe by default, then it's not visibly obvious that this is problematic.

I would much rather have the problematic thing as something visibly done by the developer, than automatically done by the compiler.
            • ... Dukc via Digitalmars-d-announce
            • ... Paolo Invernizzi via Digitalmars-d-announce
            • ... Steven Schveighoffer via Digitalmars-d-announce
        • Re: DIP10... Paolo Invernizzi via Digitalmars-d-announce
        • Re: DIP10... Steven Schveighoffer via Digitalmars-d-announce
          • Re: D... Atila Neves via Digitalmars-d-announce
            • ... ag0aep6g via Digitalmars-d-announce
            • ... Atila Neves via Digitalmars-d-announce
            • ... Dukc via Digitalmars-d-announce
            • ... Steven Schveighoffer via Digitalmars-d-announce
            • ... Joseph Rushton Wakeling via Digitalmars-d-announce
            • ... Paolo Invernizzi via Digitalmars-d-announce
            • ... Walter Bright via Digitalmars-d-announce
            • ... Steven Schveighoffer via Digitalmars-d-announce
        • Re: DIP10... ag0aep6g via Digitalmars-d-announce
          • Re: D... Atila Neves via Digitalmars-d-announce
            • ... ag0aep6g via Digitalmars-d-announce
            • ... Paul Backus via Digitalmars-d-announce
            • ... Mathias LANG via Digitalmars-d-announce
            • ... Dominikus Dittes Scherkl via Digitalmars-d-announce
  • Re: DIP1028 - Rational... jmh530 via Digitalmars-d-announce

Reply via email to