Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
willtim
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
33 ms
·
301.
▲
by
willtim
7y ago
> I still don’t appear to be wrong. Procedures are not functions! I can understand the confusion since both Java and OCaml will let you define both. Procedures have side-effects, e.g. mutating global state, (pure) functions don't.
302.
▲
by
willtim
7y ago
Thanks for the detailed reply!
303.
▲
by
willtim
7y ago
> It's a little known fact but the kind of FP programming we do in Scala tends to be more pure than what happens in OCaml, F#, Erlang, Clojure and others. I have only dabbled in Scala, but IMHO it's more suited as an OCaml with
304.
▲
by
willtim
7y ago
It's a pure function because it doesn't do any IO. It returns an action that, when run, performs the IO. Because it's a pure function, we have referential transparency, we can safely replace the function call with its compute
305.
▲
by
willtim
7y ago
Lambda calculus is a lot simpler than Python. It bares a striking similarity to Gentzens natural deduction rules and is essentially isomorphic to it. It is also very well studied and its properties are well known. Hence it makes an excell
306.
▲
by
willtim
7y ago
I think the title is tongue-in-cheek. Clearly the future is Python and JavaScript.
307.
▲
by
willtim
7y ago
That programmers are becoming more interested in maths and the mathematics of program construction can only be a good thing. As someone clearly interested in maths, I am surprised you seek to attack them as "cults". I just see ent
308.
▲
by
willtim
7y ago
At my UK state school in the 80s, they had a similar policy for musical instruments. They only gave music lessons to those that already were having private lessons (!)
309.
▲
by
willtim
7y ago
Because most statically typed languages allow us to define our own types, add type signatures to constrain etc. Dependently typed languages also allow types to depend on values. Inference is useful, but only one aspect of static typing.
310.
▲
by
willtim
7y ago
"Dynamic typing" is really just case analysis at runtime. Every static language is capable of dynamic typing, it's not some feature that statically typed languages lack. A dynamic language is really just a static language wit
311.
▲
by
willtim
7y ago
> Not automatically coercing values is all that strong typing means. It's at best a colloquial term and it's misleading to non-technical management.
312.
▲
by
willtim
7y ago
My point is that your marketing is misleading. Use "strong dynamic types" if you must, but for Python, it would be more accurate to say "strongly tagged".
313.
▲
by
willtim
7y ago
The word "type" has a specific meaning in maths/logic, which is not the same as that used by the "dynamic" languages community. Professor Bob Harper of CMU would refer to Python as unityped, i.e. having a single typ
314.
▲
by
willtim
7y ago
Type means statically typed unless you qualify it with your own nomenclature "dynamic". Please don't hijack the mathematical definition of type.
315.
▲
by
willtim
7y ago
I believe that marketing Python as "strongly typed" has the potential to confuse rather than educate. Python still crashes at runtime with these errors. It has nice error messages, but it still crashes, potentially in production.
316.
▲
by
willtim
7y ago
In my industry, the companies that have standardised on Python and consequently now have large Python codebases are not very productive environments anymore. Perhaps they were once, for the first few people, in the first few months. It'
317.
▲
by
willtim
7y ago
To understand the hate, you have to realise that no one likes being forced into using a particular technology. Especially one that is more of a lowest common denominator and ignores much of the progress in programming language research over
318.
▲
by
willtim
7y ago
Not until the libraries get built. They didn't exist for Python either until fairly recently in the history of all these languages.
319.
▲
by
willtim
7y ago
> I really enjoy working with python over any other language. I assume you mean, "over any other language I have tried" ? As someone with a mathematical background myself, I am always surprised at how many data scientists and q
320.
▲
by
willtim
7y ago
I am more productive in a language with an expressive type system (e.g. Haskell) than one without. Thinking about types not only guides me towards a working solution quickly, but the checker catches all my minor mistakes. In Haskell, you ca
321.
▲
by
willtim
7y ago
The issues discussed in that link, such as concurrency, lack of atomicity and failure are all factors that make bi-directional sync a hard problem. Yes POSIX provides few guarantees and so that burden rests on the application code above. Th
322.
▲
by
willtim
7y ago
That's really the job of the filesystem to protect against corruption using checksums. ZFS will do this and hopefully more will follow. I suppose a file sync tool could detect a change of contents with no change of mtime, but that woul
323.
▲
by
willtim
7y ago
I disagree. POSIX, although somewhat dated, has provided a good enough abstraction layer for filesystems and OSs. My proof of this is the number of different and successful filesystems for Unix/Linux. If the abstraction didn't wor
324.
▲
by
willtim
7y ago
> there's a million fiddly things to get right, and Unison hasn't had that much usage Unison is the only bidirectional sync tool that I trust to get the details right. It is backed by a formal model with various proofs of cor
325.
▲
by
willtim
7y ago
Yes Java has many issues, but writing complex GUI apps in plain C in this day and age is the wrong thing to do. The early Gnome founders learned this the hard way which led to Mono, which at least had automatic memory management. I fear thi
326.
▲
by
willtim
7y ago
My time is not free
327.
▲
by
willtim
7y ago
To quote Dijkstra, testing shows the presence, not the absence of bugs. If you want to actually prove the absence of these classes of bugs then you need a static type system.
328.
▲
by
willtim
7y ago
It's a nice error message, but it's a runtime error, it might not happen until weeks into production. It's technically just a crash with a useful error message. "strict typing that enforces type declarations" is gen
329.
▲
by
willtim
7y ago
What language are you going to try and improve? Add static types to Python? Or make Java purely functional? Often one needs to start again. Mirth looks much better than most.
330.
▲
by
willtim
7y ago
I was making the point that this would never get to Emacs mainline. But sure, no reason why it couldn't end up in a fork, but the fork is not going to give you the same "taste of freedom" ;)
More ›