I need to make my functions within my protocol @objc functions so that they can be put in selectors for my TapGesture Recognizers but I get an error that says @objc can only be used with members of classes, @objc protocols, and concrete extensions of classes. I made the protocol an @objc and it still gives the same error...
Asked
Active
Viewed 152 times
-1
-
1Do not post pictures of code. Please [edit] your question and replace the picture with your actual code, as text. – rmaddy Jun 27 '18 at 18:29
2 Answers
0
You should try this : Protocol extension on an ObjC protocol (I can't comment because I don't have the reputation needed sorry for the answer)

Quentin Rth
- 178
- 1
- 15
0
You can only declare a protocol function in a protocol, not implement it. You should be extending the UIView class to implement this protocol function.