Pattern: Wrong property accessors order
Issue: -
When declaring properties in protocols, the order of accessors should be get set
.
Examples of correct code:
protocol Foo {
var bar: String { get set }
}
protocol Foo {
var bar: String { get }
}
protocol Foo {
var bar: String { set }
}
Examples of incorrect code:
protocol Foo {
var bar: String { ↓set get }
}