mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
This adjusts the test diffing to ignore the whitespace changes across different platforms. `raw_fd_ostream` will write out `OF_Text` files with the platform's line endings, which may differ from the source file's.
13 lines
601 B
Plaintext
13 lines
601 B
Plaintext
// RUN: %target-swift-frontend -typecheck %s -swift-version 4
|
|
// RUN: %empty-directory(%t) && %target-swift-frontend -c -primary-file %s -emit-migrated-file-path %t/no_extraneous_argument_labels.result -swift-version 4 -o /dev/null
|
|
// RUN: diff --strip-trailing-cr -u %s.expected %t/no_extraneous_argument_labels.result
|
|
// RUN: %target-swift-frontend -typecheck %s.expected -swift-version 5
|
|
|
|
func foo(_ oc: [String]) {
|
|
var args: [String] = []
|
|
let dictionary: [String: String] = [:]
|
|
args.append(contentsOf: oc.map { orderedColumn in
|
|
dictionary.first { (column, value) in true }!.value
|
|
})
|
|
}
|