[SR-9391] Incorrect fix-it when trying to use a selector inside an extension of a non-objc protocol #51857
Labels
bug
A deviation from expected or documented behavior. Also: expected but undesirable behavior.
compiler
The Swift compiler in itself
diagnostics QoI
Bug: Diagnostics Quality of Implementation
Additional Detail from JIRA
md5: d624f9ffd7a333e72fcf94668d9a3359
Issue Description:
First time post, so kindly let me know if I'm going against any guidelines.
The below code prompts an error in Xcode with quick-fix stating:
However, applying the quick-fix adds `@objc` to the btnHandler line in the protocol definition instead of the instance method.
I know that @objc can't be used in non-concrete extension, however the syntax auto-correct behavior seems odd.
edit: fixed mistake in example, pointed out by @theblixguy
The text was updated successfully, but these errors were encountered: