Structs cannot inherit
suggest changeUnlike classes, structures cannot inherit:
class MyView: NSView { } // works
struct MyInt: Int { } // error: inheritance from non-protocol type 'Int'
Structures, however, can adopt protocols:
struct Vector: Hashable { ... } // works
Found a mistake? Have a question or improvement idea?
Let me know.
Table Of Contents