Skip to content

Commit 5dcaadb

Browse files
committed
Make sure to call the isEqual(to:) method and not recurse on isEqual()
1 parent 5910a9d commit 5dcaadb

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Foundation/NSDate.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ public class NSDate : NSObject, NSCopying, NSSecureCoding, NSCoding {
3030

3131
public override func isEqual(_ object: AnyObject?) -> Bool {
3232
if let date = object as? NSDate {
33-
return isEqual(date)
33+
return isEqual(to: date)
3434
} else {
3535
return false
3636
}

0 commit comments

Comments
 (0)