Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
tel
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
51 ms
·
511.
▲
by
tel
10y ago
In response only to the third point, there are some very nice examples of "advanced" equational reasoning in the work of Richard Bird. Pearls of Functional Algorithm Design [0] is a great book for exploring this and demonstrates
512.
▲
by
tel
10y ago
Parsing and generative testing are well-covered by static types, but I'll give you that contracts can enforcing things static types cannot. That said, static types can enforce things that contracts cannot, too. Furthermore, in my exper
513.
▲
by
tel
10y ago
> Immensely powerful abstraction Let's take a look. > Validation Validation typically means that given a set of shapes of data from a large class we should determine whether a certain instance fits within a smaller class. For ins
514.
▲
by
tel
10y ago
Yup! But too late to edit :( Thanks!
515.
▲
by
tel
10y ago
Another counterintuitive result in this vein is to think about randomly sampling uniformly distributed points in a sphere. As the dimension rises, the chance of finding a sample within, say, r/100 of the surface goes to infinity. In hi
516.
▲
by
tel
10y ago
Randomness is contextual. Two popular contexts for which this works are (a) I am attempting to predict an event and cannot do so deterministically using information I and resources R or (b) I am attempting to characterize a sequence of
517.
▲
by
tel
10y ago
Quotients are often used to describe new behavior. You could reasonably say that this ought to define a new type, but it's still an example of a meaningful coarsening of equality. For example, to define rational numbers using only inte
518.
▲
by
tel
10y ago
A friend of mine who has a passion for language tried to get me to learn Lojban with him for a while. It's a complete waste of time in terms of its usability. I have never even heard of someone other than this friend who has spent any
519.
▲
by
tel
10y ago
Modeling a pipeline of transformations of a well-understood data type it sort of whatever comes right after "hello world" in functional programming. A compiler is a very scaled up version of this, but it certainly fits naturally w
520.
▲
by
tel
10y ago
Stringly-typed programming considered harmful.
521.
▲
by
tel
10y ago
That's a good point. I was basing it on dates I could find and what I've been reading in Social Architecture. Perhaps the latest C4 is later and PC3 is smack in the middle
522.
▲
by
tel
10y ago
How would you review PC3 versus C4? It seems like C4 ( https://rfc.zeromq.org/spec:42/C4 ) is the latest evolution of this design. It seems to embrace optimistic merging even more than PC3 and does away with reviewers.
523.
▲
by
tel
10y ago
I just learned these were on the table last night. It's like Christmas!
524.
▲
by
tel
10y ago
There are whole fields more or less dedicated to it! In mathematics, queueing theory; in engineering pretty much the entirety of Industrial Engineering; and there are probably 10 competing frameworks in management, the most important being
525.
▲
by
tel
10y ago
Right, so I think where we're disagreeing is that the casual ones are subtly wrong. I think they're often pretty significantly wrong and that this post was essentially poking into that notion. When purity gets on the table lots of
526.
▲
by
tel
10y ago
The definition of pure function (or, dually, side effect) is difficult to pin down. I've heard a number of definitions, but the best ones are far more technical than you'd see in casual conversation and the casual ones often admit
527.
▲
by
tel
10y ago
I mean that it's not even so well defined mathematically. Starting from a weak place and then moving it to the "real world" makes things quite tricky.
528.
▲
by
tel
10y ago
Haskell is well-known not to be pure in supporting non-terminating computation.
529.
▲
by
tel
10y ago
It's not so well-defined. In particular, "side effect" is hard to pin down. For instance, a good definition ought to consider potential non-termination a side effect. In that way, many functions are impure.
530.
▲
by
tel
10y ago
Yep, sorry about that!
531.
▲
by
tel
10y ago
It's cool that Galois got this contract. They're a very nice Haskell shop out of Seattle responsible for projects like Copilot and Cryptol.
532.
▲
by
tel
10y ago
Not all types need to have induction principles. The ones that do are nicer, of course, precisely because they correspond to values.
533.
▲
by
tel
10y ago
I disagree that it's a good idea to think of types as a "collection" (loosely) of values. It may be the case that you do not distinguish computation and value (here, I'm thinking of CBPV) but types only classify values a
534.
▲
by
tel
10y ago
It's also simple enough to direct readers to note that types refer to expressions, not values. It's only through later evaluation relations do those expressions and their values end up sharing types.
535.
▲
by
tel
10y ago
But that's pretty much exactly what HOAS is avoiding ;)
536.
▲
by
tel
10y ago
Yes, I'm aware of those papers. I've read many including the one that you linked. As far as I'm aware, while you can use the strict definition ( is there, in the metalanguage, the creation of an AST? ) they're often disc
537.
▲
by
tel
10y ago
I suppose I don't really define deep and shallow in any precise way. I'd say what you describe is a "shallower" DSL than any one using HOAS, but using HOAS will be shallower than one that has an explicit binding structur
538.
▲
by
tel
10y ago
I've used it a few times. It's a cute way to make shallow DSLs which need to identify binders. It gets very annoying to do any work under the binders however making it scale poorly to many tasks important in more complex DSL imple
539.
▲
by
tel
10y ago
I'm not really interested in putting in the effort to convince you. This opinion arises from conversation I've had with users of ghcjs, developers of ghcjs, and people very familiar with GHC compilation pipeline details and runtim
540.
▲
by
tel
10y ago
Laziness doesn't just make FFI harder (although it does do that too) it also makes code generation harder and implies the need for a sophisticated runtime. All of this makes the generated code bigger, slower, and more opaque. A strict
More ›