Other articles

  1. talk at Leipzig's Haskell conference HaL-10

    As I said before: I will hold a small talk about dogelang at Leipzig's next Haskell conference HaL-10.

    Here's a translation of the abstract (original in German):

    dg - The better Haskell is named Python

    Who needs typeclasses? Or static type system even? Why have side-effects to be so complicated? And what are monads?

    There must be something better!

    dg is Python with Haskell syntax. In a short talk (15 minutes) I want to introduce, on a funny note, the "better Haskell".

    Under the slogan "what we don't have, you won't need" we will be looking at features of the Haskell language and their counterparts in dg. To conclude, we will take a look at how intelligent a Python program can look, if it has the proper syntax.

  2. dogelang adding pattern matching

    If you haven't read about dogelang, you really should. It is python with haskell-syntax where you can use all python modules. So basically coffee-script but for a language that is already useful. And python bytecode is emitted instead of first compiling to python itself, but that just as a side-node.

    On my behest, the developer of dg added pattern matching so that in an if-condition a tuple-unpacking-expression does not raise an exception if the unpacking fails but returns false.

    Therefore one can now implement their own zip and list-constructor in the following manner:

    zip = x' y' -> if
      ([x, *xs], [y, *ys] = x', y') =>
        yield (x, y)
        yield from $ zip xs ys
      otherwise => yield from ()
    list = x' -> if
      ([] = x') => []
      ([x, *xs] = x') => [x] + list xs

    This looks almost like haskell's case-pattern-matching but not quite, so it is sure to annoy every haskell-programmer.

    You might need to execute python3 -m dg -b once after installing/updating dg to rebuild the interpreter/compiler-bundle with this feature.

    In other news: It is quite likely that I will hold a small talk about dogelang at Leipzig's next Haskell conference HaL-10.



Theme based on notmyidea