Reputation: 1396
I've got a warning in Xcode 6 and 7 that says:
"Segues initiated directly from view controllers must have an identifier"
However, when I look at ALL the segues in the storyboard, they all have identifiers, and I call them all programmatically. It's not a show stopper by any means - the app builds and is totally useable. I just don't like warnings.
There are somewhat related questions like this one, but it's not the issue I'm seeing.
Are there places that hidden segues can live? Or a master list of segues that I can look at?
Upvotes: 4
Views: 2743
Reputation: 1035
Once you've followed the suggestions in this post, you might need to restart Xcode. One indication for this is that the warning count is greater than the actual number of warnings that are showing up in the warnings panel. Doing a Clean or Clean Build Folder, rebuild, etc. may not clear this warning. I've experienced this issue with builds as late as Xcode 8.2.1
Upvotes: 5
Reputation: 1698
In my case, I couldn't find a segue without an identifier even when I searched the Storyboard's Source Code (thanks @matt). What I did to remove the warning was:
Upvotes: 2
Reputation: 535617
a master list of segues that I can look at
Absolutely. Control click on the storyboard's listing in the Project navigator and choose Open As > Source Code. Now you can read — and search — the storyboard as XML. Look for a <segue ... />
without an identifier
attribute.
Upvotes: 14