Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
DanWaterworth
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
11 ms
·
61.
▲
by
DanWaterworth
10y ago
> You'll know that iterating through a linked list is O(N), binary search is O(log(N)) and a hash table lookup is O(1). What if I told you that all of the above is wrong? It's not wrong, it doesn't have enough contextual i
62.
▲
by
DanWaterworth
10y ago
It's quite confusing, the del operator means different things in each term. del of p is just the gradient of the pressure, but the convective term is more complicated. This may help [1]. The key part is: Generally the convective deriv
63.
▲
by
DanWaterworth
10y ago
The question was, "how's that?". My answer was, it's possible for a small dependently typed language to be simpler than Haskell. I'd already made the assertion that Idris was less complicated than Haskell.
64.
▲
by
DanWaterworth
10y ago
You're technically correct, but in practice, proving that software does confirm to a formal specification is, empirically, a good way of drastically reducing defects.
65.
▲
by
DanWaterworth
10y ago
It's not about turing completeness. Deducing arbitrary properties of programming written in primitive recursive languages is also undecidable. This is why type inference in dependently typed languages is undecidable.
66.
▲
by
DanWaterworth
10y ago
You don't need to solve the halting problem to write provably correct software (that is, software that conforms to a formal specification). The halting problem (and Rice's theorem) come into play when you are trying to deduce thin
67.
▲
by
DanWaterworth
10y ago
> It's generally (or maybe universally) more difficult to "get" dependent typing than plain old ML-family static typing. That's true, but Haskell has come a long way since a direct comparison like that would make sens
68.
▲
by
DanWaterworth
10y ago
Haskell's type system has accrued complexity over the years, whereas a small dependently typed language can be implemented very easily [1]. [1] https://www.andres-loeh.de/LambdaPi/
69.
▲
by
DanWaterworth
10y ago
> Haskell has no equivalent of the Idris type above, and Go has no equivalent of either the Idris type or the Haskell type. As a result, Idris can prevent many bugs that Haskell can't, and Haskell can prevent many bugs that Go can&#
70.
▲
by
DanWaterworth
10y ago
OK, that's impressive.
71.
▲
by
DanWaterworth
10y ago
This is more difficult than you might think. LLVM IR more like a family of closely related, but poorly-specified languages, than a language of its own. There is an interpreter in the LLVM codebase, but this is essentially only possible beca
72.
▲
by
DanWaterworth
10y ago
Since the network has already been trained, I can't imagine using WebGL is worthwhile. It would interesting to see, either, drawing samples from the equilibrium distribution or training in the browser.
73.
▲
by
DanWaterworth
10y ago
I'd expect either Rank2Types or RankNTypes to be included in Haskell', you may be thinking of ImpredicativeTypes. Wow, I did not realize ScopedTypeVariables had been around for so long.
74.
▲
by
DanWaterworth
10y ago
That's not anywhere near a complete list of deprecated extensions and there are others that have been completely removed from the language [1]. It's unfortunate that ScopedTypeVariables hasn't been standardised, but there has
75.
▲
by
DanWaterworth
10y ago
I don't think this is a flaw, in fact I think it neatly solves the problem of how to extend the language without committing to a design too eagerly and provides a platform for experimentation. There are pragmas that GHC implements that
76.
▲
by
DanWaterworth
10y ago
If you'd like strictness by default, there's a pragma for that https://ghc.haskell.org/trac/ghc/wiki/StrictPragma
77.
▲
by
DanWaterworth
10y ago
One way around this is to have typeclasses for all the different kinds of effects you'd like with instances for IO. Then for testing you can use a different instance that produces a value of a free monad.
78.
▲
by
DanWaterworth
10y ago
When will the machines learn...
79.
▲
by
DanWaterworth
10y ago
Same way git does?
80.
▲
by
DanWaterworth
10y ago
Same here, though in my case it was on my list of things to continue building.
81.
▲
by
DanWaterworth
10y ago
You don't need a PhD to use dependent types. I don't have a Bachelor's.
82.
▲
by
DanWaterworth
10y ago
> For instance I have yet to see an easy and simple to use (and as such maintainable) functional widget and gui library. Like react?
83.
▲
by
DanWaterworth
10y ago
It doesn't need to be finished to be useful.
84.
▲
by
DanWaterworth
10y ago
Same author: http://dev.stephendiehl.com/fun/
85.
▲
by
DanWaterworth
10y ago
You have no reason to. We're talking about a hypothetical future where PyPy has become the reference implementation.
86.
▲
by
DanWaterworth
10y ago
If you are happy using CPython, you can't be terribly concerned with performance. The point is, pypy will run on more platforms than its JIT targets.
87.
▲
by
DanWaterworth
10y ago
I mentioned it because I didn't see it in my scanning of the issue you linked to. Edit: I should have looked more closely, sorry.
88.
▲
by
DanWaterworth
10y ago
With the literate style, code is prefixed and comments are raw. So, instead of: -- foo is a function foo :: String -> String It's foo is a function > foo :: String -> String
89.
▲
by
DanWaterworth
10y ago
I'm in no way connected to the project. Perhaps you should file an issue.
90.
▲
by
DanWaterworth
10y ago
I think people interested in compilers are disproportionately Haskell inclined.
More ›