Advertisement · 728 × 90

Posts by Point-Free

Video

Spent my Friday evening exploring the new @pointfree.co TCA26 beta, connecting it to skip.tools to get the framework working on Android.

A single #swiftlang codebase, native #SwiftUI and #JetpackCompose components, and the Composable Architecture all together? THE FUTURE IS NOW

13 hours ago 8 2 1 0
Post image

Which code do you want to maintain?

Do you really want to go through 'withLock' every time you need to access state? Wouldn't it be better to just get synchronous access to your state with no ceremony?

That's what actors give us!
www.pointfree.co/episodes/ep3...

3 days ago 3 1 0 0
Post image

You may wonder why it took us 5 episodes in our “Isolation” series to get to actors, but we needed to understand locks first. There's some misunderstanding in the Swift community about how actors compare to locks, and we want to clear the air.

👉 www.pointfree.co/collections/...

4 days ago 2 0 0 0
Video

Actors finally enter the stage in our series exploring “isolation” in Swift. We will compare actors to locking and mutexes to find they are a breath of fresh air (mostly). Learn why: www.pointfree.co/episodes/ep3...

5 days ago 0 0 0 0
Preview
Video #360: Isolation: Mutex We explore the most modern locking primitive in Swift: Mutex. It has some serious smarts when it comes to protecting nonsendable state across threads in a synchronous manner, but it also has a serious...

Learn why: www.pointfree.co/episodes/ep3...

1 week ago 2 0 0 0
A Sendable error in Swift.

A Sendable error in Swift.

Sendability errors in Swift might make you wonder if you should be adding “Sendable” to all your types. It seems innocent enough, and don’t we want all our types to be concurrency-safe?

The answer: an emphatic NO!

Take great care making a type sendable 👇

1 week ago 2 0 1 0

It will be free for all eventually!

1 week ago 1 0 0 0
Post image

And we're up and running with a simple TCA 2.0 bluesky client. Just hitting some of the public endpoints to load a feed!

No auth yet, but I just did an auth0 integration a few months ago, so it should be straightforward 🤞

#atProto #swiftlang #swiftUI @pointfree.co

1 week ago 10 2 0 0
Advertisement

Haha well technically we did post on 4/1 but may not have made it to your side of the world until 4/2 :)

1 week ago 1 0 1 0
Post image

Swift's Mutex is the modern way to lock state. It relaxes many constraints while still keeping things thread safe.

But there's a serious bug. You can escape a non-sendable object from the mutex to multiple threads and cause runtime crashes.

Learn more: www.pointfree.co/episodes/ep3...

1 week ago 3 1 0 0
Preview
Beta Preview: DebugSnapshots Introducing DebugSnapshots: a new library that brings exhaustive testing to reference types. Apply the @DebugSnapshot macro to your @Observable classes and assert exactly how their state changes over…

We have a brand new open source project we are working on, and for the first time we are giving people a very early peek.

It's a library that brings exhaustive testing tools to difficult-to-test types, such as reference types.

www.pointfree.co/blog/posts/2...

1 week ago 6 0 0 0

The future is now! #swift

1 week ago 4 1 0 0

Read all about it in our announcement post: www.pointfree.co/blog/posts/2...

1 week ago 2 0 0 0

We’re releasing ComposableArchitecture 2.0 as a Beta Preview, as well as a brand new library: www.pointfree.co/beta-previews

1 week ago 2 1 1 0
ComposableArchitecture 2.0

ComposableArchitecture 2.0

We are announcing something BIG today!

1 week ago 10 1 1 2
Preview
GitHub - pointfreeco/sqlite-data: A fast, lightweight replacement for SwiftData, powered by SQL and supporting CloudKit synchronization. A fast, lightweight replacement for SwiftData, powered by SQL and supporting CloudKit synchronization. - pointfreeco/sqlite-data

Planning out a new app to start working on and @pointfree.co once again has done a tremendous amount of heavy lifting for me, this time with github.com/pointfreeco/... supporting CloudKit

1 week ago 2 1 0 0
Post image

Mutex improves on OSAllocatedUnfairLock in two ways:

• It is more flexible by using the 'sending' keyword to safely pass non-sendable objects in and out
• It is more strict since there is no lock() or unlock() method

Learn all about it:
www.pointfree.co/episodes/ep3...

1 week ago 2 0 0 0
Video

We explore the most modern locking primitive in Swift: Mutex. It has some serious smarts when it comes to protecting nonsendable state across threads in a synchronous manner, but it also has a serious bug that you should be aware of.

👉 www.pointfree.co/episodes/ep3...

1 week ago 4 1 0 0
Advertisement
Post image

OSAllocatedUnfairLock has two initializers: one requires Sendable, the other is unchecked. A 3-line extension using @‌Sendable @‌autoclosure gives you a safe way to protect non-sendable state.

Learn this trick and more in this week's episode: www.pointfree.co/episodes/ep3...

2 weeks ago 4 0 0 0
Post image

Have you tried SQLiteData yet?

github.com/pointfreeco/...

2 weeks ago 0 0 1 0
Post image

OSAllocatedUnfairLock ships two initializers: one too strict (requires Sendable), the other unchecked. A 3-line extension using @‌Sendable @‌autoclosure gives you a safe middle ground for non-sendable state.

Learn this fun trick in this week's episode: www.pointfree.co/episodes/ep3...

2 weeks ago 1 0 0 0
Preview
Video #359: Isolation: OSAllocatedUnfairLock It turns out that isolating state with an NSLock is not as straightforward as it seems, and we still have a subtle data race. But Apple actually provides a more modern tool that does help prevent…

Learn all about this in our "Swift Isolation" super series: www.pointfree.co/episodes/ep3...

2 weeks ago 2 0 0 0
Post image

NSLock was built before Swift concurrency so its API has no sendability annotations, making it easy to write unsafe code.

OSAllocatedUnfairLock is a modern replacement that uses sendability to express that you cannot capture nor return non-sendable state from it.

2 weeks ago 2 1 1 0
Post image

Some hard data on a successful conversion of a Core Data app to SQLiteData. Crashes go 📉

2 weeks ago 6 0 0 0
Post image

iCloud collaboration is a major selling point for apps, so don't leave that functionality on the ground!

SQLiteData makes it incredibly easy for your users to share records with other iCloud users. It truly only takes a few minutes to implement!

👉 github.com/pointfreeco/...

2 weeks ago 3 0 0 0
Preview
Video #359: Isolation: OSAllocatedUnfairLock It turns out that isolating state with an NSLock is not as straightforward as it seems, and we still have a subtle data race. But Apple actually provides a more modern tool that does help prevent…

See how this distinction helps prevent data races:
www.pointfree.co/episodes/ep3...

2 weeks ago 1 0 0 0
Post image

NSLock and OSAllocatedUnfairLock both have a 'withLock' method, but they are completely different.

The former is mere sugar around lock+unlock, and the latter actually protects state by wrapping it and using sendability attributes.

2 weeks ago 3 0 1 0
Post image

You might think @‌unchecked Sendable is a localized escape hatch, but it opens the floodgates for data races in unrelated code.

This week we show how it caused a crash in a completely different class that was never marked as unchecked sendable. How??

www.pointfree.co/episodes/ep3...

2 weeks ago 2 0 0 0
Advertisement
Preview
Video #359: Isolation: OSAllocatedUnfairLock It turns out that isolating state with an NSLock is not as straightforward as it seems, and we still have a subtle data race. But Apple actually provides a more modern tool that does help prevent this...

Isolating state with an NSLock is not as straightforward as it seems, and we showed a subtle data race. But Apple provides a more modern tool that helps prevent this data race at compile time. Let’s take it for a spin and understand how it works.

👉 www.pointfree.co/episodes/ep3...

2 weeks ago 0 0 0 0
Post image

Big release for Snapshot Testing: full support for Swift Testing attachments!

🎉 github.com/pointfreeco/...

3 weeks ago 2 0 0 0