3 ms·
I freely admit that I'm not exactly writing for all audiences, but I'd love to know what gave you trouble. I'm just learning Swift myself and applying some (fai
by tel 12y ago
I freely admit that I'm not exactly writing for all audiences, but I'd love to know what gave you trouble. I'm just learning Swift myself and applying some (fairly weird) techniques to it in order to get some give from its (very nice) immutable data structures.
I ended up writing this as a little background for another post I was more earnestly working on that implements a lazy, non-deterministic parser combinator library. That one might be more interesting and I'll try to write it so that you can get by without too much knowledge from this post.
- nsxwolf 12y agoIt's not so much the Swift, which I've been learning just from an application development perspective. It's that your comp sci kung fu is obviously much stronger than mine, and coupled with the fact that you're even at the point that you're dealing with Swift compiler bugs added to my fear. The article is certainly well-written, though.
- tel 12y agoThe Swift compiler bugs mostly have to do with the fact that it segfaults when it encounters recursive `enum`s and `struct`s. I wrote what the code ought to look like alongside the "fixed" bits, so perhaps that'll help make it more clear. And as far as the compsci kung fu goes—I'll admit this probably isn't the best intro to it all. It's nice that Swift gives leverage to pull these kinds of gymnastics off, though.