About 21,800,000 results
Open links in new tab
  1. Swift await/async - how to wait synchronously for an async task to ...

    Feb 3, 2022 · 77 I'm bridging the sync/async worlds in Swift and doing incremental adoption of async/await. I'm trying to invoke an async function that returns a value from a non async …

  2. How does one declare optional methods in a Swift protocol?

    One of the Swift Core Team members (I don't remember who that was exactly) said that Swift only has "optional protocol requirements" because it is needed for Obj-C interop. Also, the …

  3. ios - Swift - encode URL - Stack Overflow

    Jul 3, 2014 · I like the Swift 3 solution, but it does not work for me in Swift 4: "Cannot use mutating member on immutable value: 'urlQueryAllowed' is a get-only property".

  4. What is the "some" keyword in Swift (UI)? - Stack Overflow

    Jun 3, 2019 · Swift 5.1 does not appear to have some as a keyword, and I don't see what else the word some could be doing there, since it goes where the type usually goes. Is there a new, …

  5. Swift: print () vs println () vs NSLog () - Stack Overflow

    Sep 20, 2014 · Back in Swift 1.x, print did not add newline characters at the end of the printed string, whereas println did. But nowadays, print always adds the newline character at the end …

  6. swift2 - Swift: guard let vs if let - Stack Overflow

    The Swift Docs on Control Flow explain the idea behind that: Using a guard statement for requirements improves the readability of your code, compared to doing the same check with …

  7. How do I get the App version and build number using Swift?

    I have an IOS app with an Azure back-end, and would like to log certain events, like logins and which versions of the app users are running. How can I return the version and build number …

  8. Precision string format specifier in Swift - Stack Overflow

    Jun 5, 2014 · surprising Swift doesn't seem to support native string formatting in print (). Although this might seem trivial, this type of solution has some efficiency concerns that it create a String …

  9. How does String.Index work in Swift - Stack Overflow

    Sep 24, 2016 · It was deprecated in Swift 5 and replaced with the more explicit (String.Index (utf16Offset: l, in: s)). In my opinion this should have been a question rather than an answer e.g.

  10. How is Swift `if let` evaluated? - Stack Overflow

    How is Swift `if let` evaluated? Asked 11 years, 1 month ago Modified 7 months ago Viewed 139k times