17.07.2023 15:45, Alain De Vos пишет:
This works also:

[snipped]



Despite this time you use new you still allocate your class on stack using scope and its scope still is `dofun`. But I just want to inform you. Your solutions work. Don't get me wrong.

N.B. I would say if you do not have THE reason to manually free memory - do not do this. At all. Just let GC does its work.

    • Re: How to ... Richard (Rikki) Andrew Cattermole via Digitalmars-d-learn
    • Re: How to ... Steven Schveighoffer via Digitalmars-d-learn
      • Re: How... Alain De Vos via Digitalmars-d-learn
        • Re:... Alain De Vos via Digitalmars-d-learn
          • ... Steven Schveighoffer via Digitalmars-d-learn
        • Re:... Steven Schveighoffer via Digitalmars-d-learn
      • Re: How... Richard (Rikki) Andrew Cattermole via Digitalmars-d-learn
        • Re:... Alain De Vos via Digitalmars-d-learn
          • ... drug007 via Digitalmars-d-learn
            • ... Alain De Vos via Digitalmars-d-learn
              • ... drug007 via Digitalmars-d-learn
            • ... Alain De Vos via Digitalmars-d-learn
  • Re: How to free ... Nick Treleaven via Digitalmars-d-learn

Reply via email to