hindley-milner-parser-js

0.1.10 • Public • Published

Hindley Milner Parser

A javascript Hindley-Milner parser.

const HMP = require('hindley-milner-parser-js');
HMP.parse('hello :: Foo a => a -> String');
{
  name: 'hello',
  constraints: [
    {typeclass: 'Foo', typevar: 'a'}],
  type:
    {type: 'function', text: '', children: [
      {type: 'typevar', text: 'a', children: []},
      {type: 'typeConstructor', text: 'String', children: []}]};

Readme

Keywords

none

Package Sidebar

Install

npm i hindley-milner-parser-js

Weekly Downloads

1

Version

0.1.10

License

MIT

Unpacked Size

33.6 kB

Total Files

6

Last publish

Collaborators

  • kedashoe