01-01-2025, 11:55 PM
(01-01-2025, 10:45 AM)SMcNeill Wrote: Note: I *still* think we need a simple _MEMFREE option that frees all old blocks, just as CLOSE does all file handles.I don't think that's a good idea. It reminds me of C++ where the requested memory is automatically released; as far as I can remember.
That's one of the reasons why, as I've read, many C programmers only use parts of C++. I myself have used it in C, where one don't want that values in memory deleted because one need them again in the rest of the program. This situation occurs much more often with a professional programmer.
Main conclusion: I don't think it's a good idea to release all memory blocks with just one command. Any reserved memory should only be released explicitly, as in C. That's part of the programmer's job . . . even if it "hurts".