O
Ole Begemann
oleb.net · Personal blog · on HN since 2011
Ole Begemann, an iOS and Mac developer, writes technical articles on Swift, Apple platforms, and API design, plus monthly link roundups.
What HN saysCommenters call it invaluable for iOS and Mac development, recommend the monthly link roundups, and cite his Swift strings article.
77HN people shared it
35linked it in comments
89stories submitted
1.2Kstory points
11 months agolast shared
2011people per year2026
Most-shared posts
- 1Remote View Controllers in iOS 611 people · 8 points · first shared 2012 · discussion on HN
- 2How Dropbox Uses C++ for Cross-Platform iOS and Android Development5 people · 25 points · first shared 2014 · 1 comments on HN
- 3Understanding the iPhone 6 Plus Screen3 people · 172 points · first shared 2014 · 54 comments on HN
- 4Chris Lattner on the Realm WWDC 2017 Swift Panel3 people · 121 points · first shared 2017 · 112 comments on HN
- 5Deleting RSS Feed Items3 people · 32 points · first shared 2015 · 2 comments on HN
- 6Making illegal states unrepresentable: Types as compiler-enforced documentation3 people · 5 points · first shared 2018 · discussion on HN
- 7Roy Fielding’s REST dissertation (2018)3 people · 4 points · first shared 2019 · 1 comments on HN
- 8Apple Has (Partly) Lifted the NDA for Beta Releases3 people · 3 points · first shared 2014 · discussion on HN
- 9Strings in Swift3 people · 1 points · first shared 2014 · discussion on HN
- 10Work Habits at Apple2 people · 154 points · first shared 2014 · 74 comments on HN
- 11Chris Lattner on the Origins of Swift2 people · 120 points · first shared 2019 · 43 comments on HN
- 12Steve Jobs on the File System2 people · 58 points · first shared 2012 · 66 comments on HN
- 13What Is Structured Concurrency?2 people · 4 points · first shared 2021 · discussion on HN
- 14What's new for developers in Mac OS X Lion2 people · 4 points · first shared 2011 · discussion on HN
- 15Swift needs a better language reference2 people · 4 points · first shared 2021 · discussion on HN
What HN people wrote when they linked it
pjmlp · 2022-07-28
I do and he says exactly the same thing.
>...the goal was really to build something that you could write firmware in or that you could do scripting in, that you could write mobile apps or server apps or low-level systems code, and have it be great at all of those, not just some terrible compromise.
Taken from https://oleb.net/2019/chris-lattner-swift-origins/ to save listing to the whole interview
Feel free to actually listen to the episode as well, and also read/listen the sections on how Swift is a complete Objective-C replacement without the bad C parts.
josv · 2018-10-19
We don’t lack for wonderful writers in the Apple ecosystem. Along with objc.io I’d heartily suggest:
https://oleb.net (Ole Begemann)
https://www.mikeash.com/pyblog/ (Mike Ash)
micampe · 2014-07-11
Here is a great article about strings in Swift: http://oleb.net/blog/2014/07/swift-strings/
Short story: “number of characters” and “nth character” are more complicated questions than you might think when you deal with full Unicode text.
eelco · 2011-10-17
For iOS/Mac development, Ole Begemann's http://oleb.net/ is invaluable, especially for the monthly link roundups.
JimDabell · 2025-10-15
> Swift’s string implementation goes to heroic efforts to be as Unicode-correct as possible. […] This is great for correctness, but it comes at a price, mostly in terms of unfamiliarity; if you’re used to manipulating strings with integer indices in other languages, Swift’s design will seem unwieldy at first, leaving you wondering.
> It’s not that other languages don’t have Unicode-correct APIs at all — most do. For instance, NSString has the enumerateSubstrings method that can be used to walk through a string by grapheme clusters. But defaults matter; Swift’s priority is to do the correct thing by default.
> Strings in Swift are very different than their counterparts in almost all other mainstream programming languages. When you’re used to strings effectively being arrays of code units, it’ll take a while to switch your mindset to Swift’s approach of prioritizing Unicode correctness over simplicity.
> Ultimately, we think Swift makes the right choice. Unicode text is much more complicated than what those other languages pretend it is. In the long run, the time savings from avoided bugs you’d otherwise have written will probably outweigh the time it takes to unlearn integer indexing.
— https://oleb.net/blog/2017/11/swift-4-strings/
kevincox · 2022-03-10
The problem is that RSS doesn't really have a concept of "deleted". In general feeds just contain the newest items. Items not on the feed are generally considered old, not deleted.
You can play with heuristics like "This feed is usually sorted by published date and these entries I saw previously should still be here but are missing, maybe they were deleted" but not even have published or updated dates and they aren't always accurate.
This gets even more complicated with WebSub which allows hubs go remove entries they have already seen. So now you need to not do deletion on those requests, and if you turn down your poll rate for feeds with WebSub (which Feedly does IIRC) you might not even fetch the full feed to notice that items are missing for weeks.
The one thing that would actually be reliable here is probably Atom's pagnation and archiving extensions which you can follow to get a view of all of the items in the feed and prune missing ones. However you probably don't want to do this every fetch (otherwise it kinda defeats the point of pagnation). Maybe you could combine this with other heuristics to come up with a decent system. But I'm not even sure these have ordering guarantees so I'm not sure if you are going to fetch potentially unlimited pages just to check if an item was deleted.
If we did want to solve this problem the best option would probably be to add a tombstone element to the feed to explicitly remove items.
TL;DR as far as I am aware neither RSS or…
dpatriarche · 2017-08-21
Here's what Chris Lattner said about Kotlin this past June:
"Lattner: Swift and Kotlin evolved at about the same point in time with the same contemporary languages around them. And so the surface-level syntax does look very similar. … But if you go one level down below the syntax, the semantics are quite different. Kotlin is very reference semantics, it’s a thin layer on top of Java, and so it perpetuates through a lot of the Javaisms in its model.
"If we had done an analog to that for Objective-C it would be like, everything is an NSObject and it’s objc_msgSend everywhere, just with parentheses instead of square brackets. And a lot of people would have been happy with that for sure, but that wouldn’t have gotten us the functional features, that wouldn’t have gotten us value semantics, that wouldn’t have gotten us a lot of the safety things that are happening [in Swift].
"I think that Kotlin is a great language. I really mean that. Kotlin is a great language, and they’re doing great things. They’re just under a different set of constraints."
https://oleb.net/blog/2017/06/chris-lattner-wwdc-swift-panel/
masklinn · 2024-04-25
A companion piece to this idea (previously at Oleb’s “making illegal states unrepresentable: https://oleb.net/blog/2018/03/making-illegal-states-unrepresentable/) is “parse, don’t validate”: https://lexi-lambda.github.io/blog/2019/11/05/parse-don-t-validate/
A third piece / concept I often circle back to is a lot more subtle and difficult to grok: “Names are not type safety” (https://lexi-lambda.github.io/blog/2020/11/01/names-are-not-type-safet…
GeekyBear · 2023-05-22
> I think many also find its syntax more approachable compared to that of Rust.
Chris Lattner (of LLVM fame) did design the language with the goal of hiding complexity until it is needed.
> The concept of progressive disclosure in Swift, where you can start with something very simple and then learn complexity as you go, was totally driven by making it teachable. I personally spent a lot of time trying to make sure that the introduction to Swift could just be print("Hello World"). No semicolons, no \ns, none of that public static void main stuff. Making it simple and approachable was a strong goal, and not in a weird way where in a teaching environment there is this “Swift Prime” language that’s similar but different.
https://oleb.net/blog/2017/06/chris-lattner-wwdc-swift-panel/
progval · 2022-03-12
The web (HTTP + HTML + JS) intentionally fits the definition of a REST API. https://oleb.net/2018/rest/
In particular:
> The central idea behind HATEOAS is that RESTful servers and clients shouldn’t rely on a hardcoded interface (that they agreed upon through a separate channel). Instead, the server is supposed to send the set of URIs representing possible state transitions with each response, from which the client can select the one it wants to transition to. This is exactly how web browsers work
xenomachina · 2022-03-10
There are at least a couple of ways of indicating that an entry should be deleted in RSS and Atom, but they don't seem to be well-supported.
This blog post mentions a couple: https://oleb.net/blog/2015/11/rss-feed-item-deletions/
I vaguely recall that Microsoft also had some proposed mechanism, but I can no longer find any trace of it. I doubt anything supports it.
oflannabhra · 2020-02-24
I’ll tack on a couple sources to this:
http://pointfree.co - high quality content, emphasizing functional programming.
https://oleb.net/blog/ - blog of Ole Begemann, co author of Advanced Swift (good resource itself)
https://appventure.me - Benedikt Terhechte’s topical guides to Swift features
https://andybargh.com/blog/ Andy Bargh’s topical articles
GuB-42 · 2019-02-19
Call it a database if you wish. In fact it is probably sqlite running behind the scenes.
It is a relational model, a different way of organizing things compared to the hierarchical model of the filesystem. There is probably enough literature about that to fill your ebook library ;)
I suppose that the "library" model is what most people prefer since most modern media apps use that in some form or another. Or maybe it is because of Steve Jobs reality distortion field ( https://oleb.net/blog/2012/06/steve-jobs-on-the-file-system/ ). Still, I hate all these apps attempting to hide the filesystem from me.
panic · 2016-07-15
Here's more info about how the iPhone 6+ scales pixels in various situations if anyone's curious: http://oleb.net/blog/2014/11/iphone-6-plus-screen/
koreyhinton · 2015-05-29
Seeing there are no blogs listed for iOS dev, here are my favorites:
https://www.mikeash.com/pyblog/
http://nshipster.com/
http://natashatherobot.com/
http://oleb.net/blog/
Also I have a blog: http://koreyhinton.com/blog
Apocryphon · 2015-04-08
It's a big company, and there will certainly be diversity in experiences. But he's not the first person to talk about such situations: http://oleb.net/blog/2014/09/work-habits-at-apple/ (https://news.ycombinator.com/item?id=8389238)
It does happen.
ghshephard · 2014-11-20
Apple is at least providing some tools to help with this - for instance, you can specify a storyboard whose initial view controller will then be used as the app’s launch screen; this avoids the problem of separate launch images for all screen sizes, resolutions and orientations their app supported.
http://oleb.net/blog/2014/08/replacing-launch-images-with-storyboards/
I seem to recall Marco Arment took a bit of pride in having 100% procedurally generated graphics with overcast, so that he didn't have to create/ship any bitmapped images whatsoever.
isgood12 · 2014-11-12
I've already seen a high level post about how Dropbox does cross-platform development [1], but I think they don't go in details about the kind of issues one might face going with that approach.
[1] http://oleb.net/blog/2014/05/how-dropbox-uses-cplusplus-cross-platform…
yangmeyer · 2014-10-14
Ole Begemann recently wrote about the changes in the context of selling apps through the App Store: http://oleb.net/blog/2014/07/eu-vat-changes-2015/
Apple sells all apps through its Luxemburg subsidiary, meaning Luxemburg's low 15% VAT rate applied.
On the buyer side, am I right to assume that as a VAT-registered company/freelancer I will be able to deduct VAT paid on apps purchased through the App Store?
alexbilbie · 2014-09-24
Some info about the VAT changes can be found here - http://oleb.net/blog/2014/07/eu-vat-changes-2015/
stigi · 2014-09-11
Apparently launch images in different sizes will go away and will be replaced by storyboards with auto layout
http://oleb.net/blog/2014/08/replacing-launch-images-with-storyboards/
therealmarv · 2014-09-07
When I wanted to code a foundation of reusable code for different devices I would either do it like Dropbox and use C++ as the most common layer http://oleb.net/blog/2014/05/how-dropbox-uses-cplusplus-cross-platform… or use Javascript (which I can also use for web pages) for the program logic like described here http://www.skyscanner.net/blogs/developing-mobile-cross-platform-libra…
Also interesting http://kivy.org allows you to use Python for iOS, Android, OS X and Windows.
I would not bet on Swift and cross compiling it today... too bleeding edge. But interesting project... hope it matures. Good luck!
hrabago · 2014-06-09
It seems Apple has reduced the scope of the NDA this year.
http://oleb.net/blog/2014/06/apple-lifted-beta-nda/
rince · 2014-06-09
There was a blog post about this
http://oleb.net/blog/2014/06/apple-lifted-beta-nda/
Further, Apple agrees that You will not be bound by the foregoing confidentiality terms with regard to technical information about pre-release Apple Software and services disclosed by Apple at WWDC (Apple’s Worldwide Developers Conference), except that You may not post screen shots, write public reviews or redistribute any pre-release Apple Software or services.
0x0 · 2014-05-12
There's stuff here about a UIRemoteWebViewController:
http://oleb.net/blog/2012/10/more-on-remote-view-controllers/
https://github.com/nst/iOS-Runtime-Headers/blob/master/Frameworks/UIKi…
https://github.com/nst/iOS-Runtime-Headers/blob/master/Frameworks/UIKi…
dunham · 2014-05-12
They might be able to handle it with a remote view controller. An existing iOS technology that allows for a view controller that fronts an out-of-process application. This is used for the mail composer and facebook sharing.
See: http://oleb.net/blog/2012/10/remote-view-controllers-in-ios-6/
(I suspect there are some constraints on how a remote view controller can be used, and they'd have to do some additional work to shunt in NSURLProtocol and all.)
Aqua_Geek · 2014-01-24
iOS has support for something called XPC. IIRC, it's how the mail composer, etc is invoked by apps (behind the scenes). I'd be very surprised if the API isn't made public in the next version of iOS, which would help facilitate some of these things - it would at least allow easier app-to-app integration.
More info: http://oleb.net/blog/2012/10/remote-view-controllers-in-ios-6/
pirateking · 2013-11-11
XPC[1][2] is a private framework in iOS. I am hoping it will be made accessible before iOS 8 (unlikely).
[1] http://oleb.net/blog/2012/10/remote-view-controllers-in-ios-6/
[2] https://developer.apple.com/library/mac/documentation/MacOSX/Conceptua…
pi18n · 2013-05-16
They might be moving towards some kind of XPC service so you can talk to a JIT through a Mach port.
Speculation is my own, derived from: http://oleb.net/blog/2012/10/remote-view-controllers-in-ios-6/
rye · 2013-03-20
This website actually crashes my macbook pro.
No really. I have this bug (verified by genius tech) http://oleb.net/blog/2012/05/15-inch-mbp-mid-2010-crashing-to-black-sc… which I haven't given to them for repair yet.
The Product button's visual transition repeatedly crashes my box.
Otherwise, looks pretty cool :)