I have 3 view controllers: Main, List and Run. (More will be added later.) I'm using storyboards and segues. The target OS is iOS 8. Main is the initial scene/controller. At present, I am not using any navigation controllers.
A button on Main presents List via a show segue. Depending on user interaction, List may return to Main using an unwind segue or be overlayed by Run using a show segue via performSegueWithIdentifier programatically. So far, so good.
Once List segues to Run, list will never be used again. Run will never unwind to List.
When the user exists Run, an unwind segue is fired taking the user back to Main. The problem is that List never gets deactivated. (In swift, List.deinit() is never called.) I am careful to nil all pointers to List (including delegates) before the segue from List to Run. If List unwinds to Main directly, without presenting Run, List is deallocated just as it should be.
So, what am I doing in the List-to-Run followed by Run-to-Main segues that prevents List from being deallocated?
Note that I am not using a navigation controller because I don't need the navigation bar (I know it can be hidden), and because List is not the only VC that can segue to Run; there will be several others.