typescript compilator implementation on haskell