Unused Protocols (iOS)

The unused protocol insight finds any protocols in your app binary that no type conforms to. This indicates a protocol that can be removed. However, it may not be entirely unused because you still could have code like:

if let protocolType = input as? MyProtocol {

If MyProtocol was unused, this cast would never succeed and could be removed.

You also might see the unused protocol insight even when you see types in your code that does conform to the protocol. This would mean the type that conforms to the protocol isn't included in the binary uploaded to Emerge. The type could be getting stripped, or could be compiled out with something like an #if DEBUG check. You can move the protocol behind a check like this as well to fix the insight.