4 ms·
I had a similar feeling recently using Swift for a project. Pure JavaScript is definitely a bit too loose for my liking, but I thought Swift went a bit too far
by jmkni 5y ago
I had a similar feeling recently using Swift for a project.
Pure JavaScript is definitely a bit too loose for my liking, but I thought Swift went a bit too far in the other direction.
- Aaargh20318 5y agoI had that experience with Swift for maybe the first 2 days I used it. Nowadays I really appreciate Swift’s strictness. It just helps prevent so many stupid mistakes. I worked on a high-profile project for my company under a strict deadline and Swift was a major part in ensuring we delivered a rock-solid implementation in record time.
- kalleboo 5y agoThe only part of the type system that I feel gets tedious is dealing with numbers, where you're continually casting back and forth between Int, Float, Double, CGFloat (at least the latter is being addressed). I get why it's strict about it due to loss of precision and the madness of floating-point numbers, but sometimes you just don't care
- Aaargh20318 5y agoThe number things isn't that big of an issue once you get used to considering what type your numbers should be in advance, instead of going back and forth between number types, pick one that's appropriate and stick to it.