This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| let label = UILabel() | |
| label.text = "Swift is a modern, intuitive programming language crafted for all Apple platforms." | |
| label.setValue(true, forKey: "marqueeEnabled") | |
| label.setValue(true, forKey: "marqueeRunning") | |
| label.setValue(0, forKey: "marqueeRepeatCount") |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /// A task that is cancelled if goes out of scope, i.e. the last reference on it has been discarded. | |
| public final class ScopedTask<Success: Sendable, Failure: Error>: Sendable { | |
| /// The underlying task | |
| let wrapped: Task<Success, Failure> | |
| /// Wraps a task into a scoped task. | |
| init(wrapping task: Task<Success, Failure>) { | |
| wrapped = task | |
| } |
OlderNewer