I immediately thought about that as well. I wonder how they pull it off? Swift is not a functional language, so they just save every single variable, or what?
Time travel debugging has existed for a long time, and it's not limited to functional languages; the most obvious way they could do this is through checkpointing.
Checkpointing is a natural fit with the Cocoa API, which uses an event loop. Just save the state of the application after each event is handled.
Just a hunch, LLVM uses Static-Single-Assignment, which is just that, saving every single variable change.