3 ms·
> If I have a class I can't modify and that doesn't conform to protocol `Foo`, can I make it conform to that protocol? Yes, you can.
by faical 9y ago
> If I have a class I can't modify and that doesn't conform to protocol `Foo`, can I make it conform to that protocol?
Yes, you can.
- fauigerzigerk 9y agoNot sure if that's a good thing though. I read some of the Swift standard library source code and found it very difficult to piece together all the stuff added by extensions, where they come from and where the original class definition is. Obviously, it's going to be easier if you have written the code yourself, but what if someone else needs to read it?
- hota_mazi 9y agoCan you point to the relevant documentation section? I couldn't find it.