On Monday, 25 May 2020 at 12:30:11 UTC, Zoadian wrote:
On Monday, 25 May 2020 at 10:41:43 UTC, rikki cattermole wrote:
It is meant to mean that at some point it has been
mechanically checked by the compiler.
Either during current compilation or a prior one.
Which means it has to be valid on function declarations
without bodies so i.e. .di file generation works correctly
which is just a generated D file, nothing special syntax of
semantics wise.
.di files _could_ just use @trusted instead of @safe. but for
extern(D) we could at least add it to the name mangling. it's
still not 100% safe, but at least you'd have to work hard to
get it wrong.
It's been proposed before that @safe and @trusted should have the
same mangling, since there's no difference between them from the
calling code's perspective.