We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b6755e6 commit c174e46Copy full SHA for c174e46
Guides/Merge.md
@@ -6,10 +6,10 @@
6
Merges two or more asynchronous sequences sharing the same element type into one singular asynchronous sequence.
7
8
```swift
9
-let appleFeed = URL("http://www.example.com/ticker?symbol=AAPL").lines.map { "AAPL: " + $0 }
10
-let nasdaqFeed = URL("http://www.example.com/ticker?symbol=^IXIC").lines.map { "^IXIC: " + $0 }
+let appleFeed = URL(string: "http://www.example.com/ticker?symbol=AAPL")!.lines.map { "AAPL: " + $0 }
+let nasdaqFeed = URL(string:"http://www.example.com/ticker?symbol=^IXIC")!.lines.map { "^IXIC: " + $0 }
11
12
-for try await ticker = merge(appleFeed, nasdaqFeed) {
+for try await ticker in merge(appleFeed, nasdaqFeed) {
13
print(ticker)
14
}
15
```
0 commit comments