Recent

Author Topic: Writable access to TMap and TDicrionagy values content  (Read 702 times)

zamtmn

  • Hero Member
  • *****
  • Posts: 650
Writable access to TMap and TDicrionagy values content
« on: February 20, 2024, 09:09:10 pm »
A loophole with access to private fields in the generics specialization has recently been closed. This could have been used for access with an entry in the heirs, but it no longer works((

Sometimes it is necessary to quickly change the values without iterators. I suggest we discuss https://gitlab.com/freepascal.org/fpc/source/-/issues/40656 and https://gitlab.com/freepascal.org/fpc/source/-/merge_requests/593

zamtmn

  • Hero Member
  • *****
  • Posts: 650
Re: Writable access to TMap and TDicrionagy values content
« Reply #1 on: March 18, 2024, 10:38:53 am »
It's strange that no one cares about this. Yes, of course you can use iterators, but this is the overhead of creating a class (allocating memory), which, for example, in the case of TMap is completely meaningless, there are no virtual methods in the iterator

 

TinyPortal © 2005-2018