top | item 44652378

(no title)

brandonasuncion | 7 months ago

And for times you need a fast heap-allocated type, Swift's Noncopyable types have been pretty great in my experience. Especially so for graph data structures, where previously retains/releases would be the biggest slowdown.

Example here: https://forums.swift.org/t/noncopyable-generics-in-swift-a-c...

An added plus is that the Swift compiler seems to stack-promote a lot more often, compared to class/ManagedBuffer implementations.

discuss

order

No comments yet.