seeaya

joined 1 year ago
[–] [email protected] 2 points 5 months ago

You can use swift package manager to create an executable target, which you can then run on macOS from the command line. Most frameworks (aside from UI) are shared between iOS and macOS like AVFoundation. If you don’t have access to macOS, you can still use swift package manager to build and run code on Linux or Windows, though you unfortunately won’t have access to any Apple frameworks.

[–] [email protected] 24 points 6 months ago (1 children)

The article discusses that organic foods are worse for the environment.

[–] [email protected] 2 points 8 months ago* (last edited 8 months ago) (1 children)

When Apple introduced the iPhone they required automatic reference counting to be used in Objective-C rather than tracing garbage collection (the language supported both) due to performance reasons (iPhones were significantly slower than Macs). At least Apple seems to think that reference counting is faster than tracing garbage collectors. The compiler can do a lot to remove unnecessary releases and retains. Additionally each retain is just incrementing an integer, and each release is just decrementing an integer and comparing the integer to 0, so the overhead is pretty small.