Lobste.rs

A bidirectional typechecking puzzle

Node JS vs Angular: How They Work in Modern Web Apps

Recently I stumbled across a bidirectional typechecking puzzle in my Grace programming language that I thought people interested in programming language theory might find interesting. The context is that Grace is based on a bidirectional typechecking system (specifically: Complete and Easy Bidirectional Typechecking for Higher-Rank Polymorphism) and as Grace evolved I began to run into a few limitations of that approach. Some of these limitations I could workaround with various hacks but recently these workarounds piled up to generate a bizarre bug. The problem To illustrate the bug, consider this Grace program: let authorities = [ { domain: “google.com” } , { domain: “localhost”, port: 8080 } ] for { domain, port = 443 } of authorities in “${domain}:${show port}” You can read this…

Continue reading at Lobste.rs haskellforall.com
Advertisement