Skip to content
This repository was archived by the owner on Nov 23, 2017. It is now read-only.
This repository was archived by the owner on Nov 23, 2017. It is now read-only.

Data constructors can't take arrays or tuples #162

@brow

Description

@brow

I noticed that the following type declarations don't parse:

data Tree a = Tree a [Tree a]
data Point = Point (Number, Number)

Is there a way, then, to define data constructors that take arrays or tuples? It seems like the former can be hacked in just by defining a syntactically sugar-free synonym for [a]. Then we can write:

data Tree a = Tree a (List (Tree a))

However, I can't find any such synonym in the docs or examples.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions