November 05, 2020
https://issues.dlang.org/show_bug.cgi?id=21365

          Issue ID: 21365
           Summary: TypeInfo.swap must not allow reachable memory to be
                    freed if interrupted for a garbage collection pass
           Product: D
           Version: D2
          Hardware: All
                OS: All
            Status: NEW
          Severity: normal
          Priority: P1
         Component: druntime
          Assignee: nobody@puremagic.com
          Reporter: n8sh.secondary@hotmail.com

If the type might contain pointers perform the swap in pointer-sized chunks in case a garbage collection pass occurs partway through the function. Directly affected TypeInfo subclasses that were not overriding swap:

- TypeInfo_AssociativeArray
- TypeInfo_Class
- TypeInfo_Delegate
- TypeInfo_Interface
- TypeInfo_Struct

--