Skip to content

Foundation: remove future fixes #1902

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Feb 13, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Foundation/NSURL.swift
Original file line number Diff line number Diff line change
Expand Up @@ -493,7 +493,7 @@ open class NSURL : NSObject, NSSecureCoding, NSCopying {

open var password: String? {
let absoluteURL = CFURLCopyAbsoluteURL(_cfObject)
#if os(Linux) || os(Android) || CYGWIN
#if os(Linux) || os(Android) || os(Windows)
let passwordRange = CFURLGetByteRangeForComponent(absoluteURL, kCFURLComponentPassword, nil)
#else
let passwordRange = CFURLGetByteRangeForComponent(absoluteURL, .password, nil)
Expand Down
8 changes: 0 additions & 8 deletions Foundation/Stream.swift
Original file line number Diff line number Diff line change
Expand Up @@ -153,11 +153,7 @@ open class InputStream: Stream {
}

open override var streamStatus: Status {
#if os(Windows)
return Stream.Status(rawValue: UInt(CFReadStreamGetStatus(_stream).rawValue))!
#else
return Stream.Status(rawValue: UInt(CFReadStreamGetStatus(_stream)))!
#endif
}

open override var streamError: Error? {
Expand Down Expand Up @@ -209,11 +205,7 @@ open class OutputStream : Stream {
}

open override var streamStatus: Status {
#if os(Windows)
return Stream.Status(rawValue: UInt(CFWriteStreamGetStatus(_stream).rawValue))!
#else
return Stream.Status(rawValue: UInt(CFWriteStreamGetStatus(_stream)))!
#endif
}

open class func toMemory() -> Self {
Expand Down