D not considered memory safe
Walter Bright
newshound2 at digitalmars.com
Thu Jul 11 16:23:08 UTC 2024
On 7/11/2024 12:53 AM, Paolo Invernizzi wrote:
> So, the solution is just turn your program into a gigantic facade of @safe,
> until you have time to refactor it as really @safe?
Yes.
Let's say you have a spaghetti flow graph of a pile of functions calling each
other. Some of them are not safe, and so the functions that call the functions
that call the functions are not safe, in recursive cycles (like the compile
implementation!). How do you go about making the whole thing safe? It's most
practical to do things incrementally - so mark everything trusted, and then,
starting with the leaves, rework them to make them safe.
Trying to redo it all in one go is only going to lead to frustration.
More information about the Digitalmars-d
mailing list