Undo on develop undoes too much
Using the latest develop commit ( ec3f7ebcfde4fe48ff09d0557b0a1d729ab310f9 ), undo seems to behave strangely. It seems to undo too much. For example, on master, undo reverts the auto completion of an image literal:

The same edit using develop seems to undo to the point of my first insertion:

Please try the latest develop. I discovered I was mis-using the Swift API which has a concept of 'edit transactions', as well as undo groupings. Edit transactions can only be opened/closed on a single pass of the run-loop, whereas undo groupings can exist for multiple passes.
I'm still seeing this issue after building from the develop branch
Please try again. Just committed another change to develop.
@antmd It seems to be working better, but I'll keep an eye out and let you know if I see any weirdness. Thanks for the quick fix!
@antmd I'm seeing some issues again. It's after Xcode has been open for awhile, this issue starts to come back