So generally, the more invariants you manage to capture in your types, the more categories of bugs you can statically prove will never happen.
1,132 karma · joined January 2, 2012
So generally, the more invariants you manage to capture in your types, the more categories of bugs you can statically prove will never happen.
Also, Purescript's FFI is really easy to use (unlike Elm's), afaik this was one of its original design goals.
However, if not, you'll still have a list of compiler errors you have to fix to make the rest of the program work. This alone lets me refactor with confidence, much more so than every dynamic language I've ever used.
Sure, let's say not being allowed to build minarets because people don't like that is bullshit.
But let's also imagine I buy some land in front of the kindergarden your children go to and build a giant wall showing hardcore porn movies all day. Now probably you and the majority of people living there wouldn't like me to do that, but it's my damn right so gtfo.
It's a slippery slope both ways (minarets, gay people can't kiss in public, porn walls) and I have no idea how to draw the line between what the majority wants and the invasion of personal freedom. More importantly, neither the majority nor any elected officials should be allowed to draw that line (almost by definition), so it seems it's a catch 22 situation.
* Javascript has Flow/TypeScript
* Python has PEP 484
* Perl6 has some sort of types
* Clojure/Script has core.typed, schema and now clojure.spec
* Don't know about Ruby, but I've seen articles on type checking/annotations
* Erland has Dialyzer (although this is not a recent development)
I bet the 10000 Ruby guys are gonna create a big, unmaintainable, broken mess. Even Java's primitive type system would be a big help when it's about software development at scale.
Yes yes, TDD :)
This is probably far away from being able to translate languages perfectly, but still. The future came pretty fast.
Seeing you know what a logical phallacy is, here is one more for you: "if you don't like macros you don't know how to use them". Can you guess the name?
My question was not ad hominem. I wanted to see whether you have actually used the thing you are arguing against or instead just blindly praising something as the ultimate solution and thereby determine whether I should continue this discussion with you.
(I can send you examples of macros I've had to write, if you desire.)
f x . g
reads just so much easier than (comp (partial f x) g)However, looking back at Lisp/Clojure now I really don't like the syntax anymore. I don't care about the brackets, it's absolutely true that you learn to look past them in a matter of days, but the homogeneity and the "denselesness" really impact my ability to quickly parse an expression. Infix syntaxes make reading code much easier, imo.
The point is that even if there were some yet undiscovered particles or forces, they wouldn't have any effect whatsoever on the world around us. This we can say with certainty. Even if it turns out that our current understanding of QM or GR are just approximations of the real laws of physics, again, this won't matter, much as GR doesn't matter at the speed of a moving car and thus you wouldn't take time dilation into account when you calculate the time you need to get from point A to point B.