Skip to content

Commit 168df62

Browse files
authored
Merge pull request swiftlang#917 from KingOfBrian/bugfix/SR-1762-Remove-Final-In-Protocol-Extensions
Remove final from vars in error related protocol extensions
2 parents d99eb66 + f61b424 commit 168df62

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

Foundation/NSError.swift

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -377,8 +377,8 @@ extension __BridgedNSError where Self: RawRepresentable, Self.RawValue: SignedIn
377377
}
378378

379379
public extension __BridgedNSError where Self: RawRepresentable, Self.RawValue: SignedInteger {
380-
public final var _domain: String { return Self._nsErrorDomain }
381-
public final var _code: Int { return Int(rawValue.toIntMax()) }
380+
public var _domain: String { return Self._nsErrorDomain }
381+
public var _code: Int { return Int(rawValue.toIntMax()) }
382382

383383
public init?(rawValue: RawValue) {
384384
self = unsafeBitCast(rawValue, to: Self.self)
@@ -392,7 +392,7 @@ public extension __BridgedNSError where Self: RawRepresentable, Self.RawValue: S
392392
self.init(rawValue: RawValue(IntMax(_bridgedNSError.code)))
393393
}
394394

395-
public final var hashValue: Int { return _code }
395+
public var hashValue: Int { return _code }
396396
}
397397

398398
// Allow two bridged NSError types to be compared.
@@ -403,8 +403,8 @@ extension __BridgedNSError where Self: RawRepresentable, Self.RawValue: Unsigned
403403
}
404404

405405
public extension __BridgedNSError where Self: RawRepresentable, Self.RawValue: UnsignedInteger {
406-
public final var _domain: String { return Self._nsErrorDomain }
407-
public final var _code: Int {
406+
public var _domain: String { return Self._nsErrorDomain }
407+
public var _code: Int {
408408
return Int(bitPattern: UInt(rawValue.toUIntMax()))
409409
}
410410

@@ -420,7 +420,7 @@ public extension __BridgedNSError where Self: RawRepresentable, Self.RawValue: U
420420
self.init(rawValue: RawValue(UIntMax(UInt(_bridgedNSError.code))))
421421
}
422422

423-
public final var hashValue: Int { return _code }
423+
public var hashValue: Int { return _code }
424424
}
425425

426426
/// Describes a raw representable type that is bridged to a particular

0 commit comments

Comments
 (0)