Skip to content

Fail to compile in iOS 18 #21

@yong543210

Description

@yong543210
public static func ==<T: HDUValue>(lhs: HDUValue, rhs: T?) -> Bool {       // --- line 0 ----
    guard type(of: lhs) == T.self else { return false }
    if let right = rhs {
        return lhs.hashable == right.hashable
    } else {
        return false
    }
}

Xcode complains:

/SourcePackages/checkouts/fitscore/Sources/FITS/HDU/HEADER/HDUValue.swift:109:24 Member operator '==' of protocol 'HDUValue' must have at least one argument of type 'Self'
on line 0 above.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions