4 ms·
Have you had much success adopting consume and borrow? Once you need anything in the swift standard library, you can't use a non-copyable struct with it. The k
by jarjoura 2y ago
Have you had much success adopting consume and borrow?
Once you need anything in the swift standard library, you can't use a non-copyable struct with it. The keywords are all in too, so either you write completely self-contained rust-like code that doesn't touch your other code, or you revert back to using the older copyable types.
I've tried many times to ease into using them, but I can never stick with them, and eventually revert.
I do really like the high-level design though and look forward to it evolving into something usable.
- conradev 2y agoNope. The ergonomics are really bad at the moment. I also had to revert any places I used them in API surface. I haven’t had a use case yet where I could use them privately in the internal functioning of a type. I thought borrowing could still be used with Copyable types, though