Pattern: Use of legacy constant
Issue: -
Struct-scoped constants are preferred over legacy global constants.
Examples of correct code:
CGRect.infinite
CGPoint.zero
CGRect.zero
CGSize.zero
NSPoint.zero
NSRect.zero
NSSize.zero
CGRect.null
CGFloat.pi
Float.pi
Examples of incorrect code:
↓CGRectInfinite
↓CGPointZero
↓CGRectZero
↓CGSizeZero
↓NSZeroPoint
↓NSZeroRect
↓NSZeroSize
↓CGRectNull
↓CGFloat(M_PI)
↓Float(M_PI)