CList memory management flag

 

Hi

https://www.mql5.com/en/docs/standardlibrary/datastructures/clist/clistdelete

indicates the benefit of enabling the memory management flag. How can I set it so that the memory used for the deleted element is released.

I could not see that in the example code.


Thanks

Documentation on MQL5: Standard Library / Data Collections / CList / Delete
Documentation on MQL5: Standard Library / Data Collections / CList / Delete
  • www.mql5.com
Standard Library / Data Collections / CList / Delete - Reference on algorithmic/automated trading language for MetaTrader 5
 

It's already set to do that by default. If you need to turn it off you would set FreeMode to false. 

list.FreeMode(false);
Reason: