exilon / QuickLib

Quick development library (AutoMapper, LinQ, IOC Dependency Injection, MemoryCache, Scheduled tasks, Json and Yml Config and Options pattern, Serializers, etc) with crossplatform support for Delphi/Firemonkey (Windows,Linux,OSX/IOS/Android) and freepascal (Windows/Linux).
Apache License 2.0
639 stars 187 forks source link

Automapper copy object reference instead of content #119

Closed mborgues closed 2 months ago

mborgues commented 1 year ago

When an object has a second internal object (in my case a TArray), it is copying its reference instead of the content, however when I destroy the source object it generates an "invalid pointer operation" error, precisely because the reference assigned to the mapped object refer to the previous one.

the object (the destination object has the same fields): image

the code: image

the error: image

exilon commented 9 months ago

Could you provide a quick code example?

exilon commented 2 months ago

This issue was closed because it has been open for more than 90 days with no activity.