2,016 karma · joined June 2, 2010
https://github.com/swiftlang/swift-evolution/blob/main/propo...
I say limited because the compiler doesn't (yet, as of 6.2) perform typed throw inference for closures (a closure that throws is inferred to throw `any Error`). I have personally found this sufficiently limiting that I've given up using typed throws in the few places I want to, for now.
https://en.wikipedia.org/wiki/Unicode_subscripts_and_supersc...
When it did understand my code, it was much better than Xcode for navigating and refactoring.
Also, AppCode couldn't edit or even display XIBs so I often had to keep Xcode running alongside it anyway to edit XIBs and make connections between XIB and code, and that was a hassle.
Isn't it? https://github.com/Ultimaker/Cura
Interesting to note that the parametric equations of the spiral are linear in spherical coordinates. https://en.wikipedia.org/wiki/List_of_common_coordinate_tran...
https://developer.apple.com/videos/play/wwdc2023/10054/?time...
d2 = x^2+y^2
-- 6 / pi = 1.909859317102744
angle = 6 + 1.909859317102744 * atan(x, y)
if z ~= 0 or d2 > 20 then return EMPTY end
if d2 < 11 then return GREEN end
if angle > t then return PURPLE end
-- ugly special case because reference isn't smooth at 13
if t == 13 or angle + 12 > t then return RED end
return PURPLEIt's probably still slow (I haven't been to Disney in a while) but no longer mentions HP.
https://developer.apple.com/documentation/uikit/uiviewcontro...
Swift also has two versions of a `default` case in switch statements, like you described. It has regular `default` and it has `@unknown default`. The `@unknown default` case is specifically for use with non-frozen enums, and gives a warning if you haven't handled all known cases.
So with `@unknown default`, the compiler tells you if you haven't been exhaustive (vs. the current API), but doesn't complain that your `@unknown default` case is unreachable.
I'm a happy, paying Typora (on macOS) customer. Looking at the linked page, I would never have guessed that IF is at all a Typora competitor.
I love Typora because it is a great, flexible WYSIWYG-ish Markdown editor (at least for me), and that is how it bills itself: “A minimal Markdown editor and reader.”
The linked page about IF doesn't mention Markdown at all… but it does mention things like “todo” and “pomo” and “schedule”. What do those have to do with editing Markdown?
But for something that's essentially a countertop toaster oven, I don't think French doors make a whole lot of sense. My Breville countertop toaster oven has a normal fold-down door and I have never felt like it's getting in the way.
Java for Everything
https://www.teamten.com/lawrence/writings/java-for-everythin...
Previously HN discussion of "Java for Everything":
Probably for the same reason that, in Swift, dictionary lookup returns an Optional but Array traps on out-of-bounds: dictionary keys tend to come from outside the dictionary, but array indices tend to be derived from the array bounds. This means a dictionary lookup failure tends to be expected, and an out-of-bounds array index tends to be a logic error. More details here: https://stackoverflow.com/a/75780575/77567