mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
This function points the ivar offsets at per-metadata field offsets before passing off the class to the Objective-C runtime, ensuring we don't slide the global ivar offsets multiple times. The swift_initializeSuperclass() function does not do this ivar cloning, so it cannot be used for generic classes even if they do not have generically-sized fields. An alternative would be to refactor the runtime to clone ivar offset vectors in swift_initializeSuperclass(), but this doesn't seem to be worth it for now.
4.4 KiB
4.4 KiB