Skip to content

Commit

Permalink
Fix build error
Browse files Browse the repository at this point in the history
feature/init-positional-with-argument-rep
  • Loading branch information
roanutil committed Oct 30, 2024
1 parent aed2260 commit da3572d
Showing 1 changed file with 8 additions and 22 deletions.
30 changes: 8 additions & 22 deletions Tests/ArgumentEncodingTests/ArgumentGroupTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -250,28 +250,14 @@ final class ArgumentGroupTests: XCTestCase {
}
}

#if swift(>=6) && swift(<6.0.2)
extension Array: @retroactive ArgumentGroup, @retroactive FormatterNode {
public var flagFormatter: ArgumentEncoding.FlagFormatter { FlagFormatter(prefix: .doubleDash) }
extension Array: ArgumentGroup, FormatterNode {
public var flagFormatter: ArgumentEncoding.FlagFormatter { FlagFormatter(prefix: .doubleDash) }

public var optionFormatter: ArgumentEncoding.OptionFormatter { OptionFormatter(prefix: .doubleDash) }
}

extension Dictionary: @retroactive ArgumentGroup, @retroactive FormatterNode {
public var flagFormatter: ArgumentEncoding.FlagFormatter { FlagFormatter(prefix: .doubleDash) }

public var optionFormatter: ArgumentEncoding.OptionFormatter { OptionFormatter(prefix: .doubleDash) }
}
#else
extension Array: ArgumentGroup, FormatterNode {
public var flagFormatter: ArgumentEncoding.FlagFormatter { FlagFormatter(prefix: .doubleDash) }

public var optionFormatter: ArgumentEncoding.OptionFormatter { OptionFormatter(prefix: .doubleDash) }
}
public var optionFormatter: ArgumentEncoding.OptionFormatter { OptionFormatter(prefix: .doubleDash) }
}

extension Dictionary: ArgumentGroup, FormatterNode {
public var flagFormatter: ArgumentEncoding.FlagFormatter { FlagFormatter(prefix: .doubleDash) }
extension Dictionary: ArgumentGroup, FormatterNode {
public var flagFormatter: ArgumentEncoding.FlagFormatter { FlagFormatter(prefix: .doubleDash) }

public var optionFormatter: ArgumentEncoding.OptionFormatter { OptionFormatter(prefix: .doubleDash) }
}
#endif
public var optionFormatter: ArgumentEncoding.OptionFormatter { OptionFormatter(prefix: .doubleDash) }
}

0 comments on commit da3572d

Please sign in to comment.