Haskell
  • A Proper X86 Assembler in Haskell Using the Escardó-Oliva Functional

    by Vanessa McHale | Haskell

    Writing an assembler turns out to be an interesting example: one needs to calculate distances between jumps and their target labels, and the target may appear after the label. It turns out that one can write a one-pass assembler using the tardis monad or in Curry, using logic programming.

  • Strides Are Scans

    by Vanessa McHale | Haskell

    For an array with dimensions \(n_1,n_2,\ldots n_r\) stored in column-major order, an element with indices \(a_1,a_2,\ldots a_n\) is located at offset

  • Streaming Compression/decompression in Haskell via Laziness

    by Vanessa McHale | Haskell

    In Haskell, one can present a streaming compression/decompression API with lazy bytestrings.

  • Num Instances for ASTs

    by Vanessa McHale | Haskell

    One can define a Num instance in Haskell for ASTs of expressions, viz.

  • Laconic Haskell

    by Vanessa McHale | Haskell

    Haskell programmers have an undue reputation for writing obfuscated code, perhaps due to the fondness for pointfree code and higher-order functions. However the commitment to terseness is dubious at best; syntax is rarely exploited.