Skip to content

Conversation

telser
Copy link
Contributor

@telser telser commented Feb 13, 2016

No description provided.

(:) = Cons
cons :: forall a. a -> List a -> List a
cons = Cons
infixr 6 cons as :

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

With this definition for (:) I get the following error when trying to use it to pattern match (using 0.8.2):

Operator (:) cannot be used in a pattern as it is an alias for function cons. Only aliases for data constructors may be used in patterns.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, as of v0.8.2 this should be infixr 6 Cons as : instead 👍

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah yes, will fix. Thanks for pointing it out.

@telser telser force-pushed the purescript-0.8-warnings branch 2 times, most recently from e8272df to f0f607b Compare March 3, 2016 01:49
@telser telser force-pushed the purescript-0.8-warnings branch from f0f607b to a32e5db Compare March 3, 2016 02:02
@nullobject
Copy link
Contributor

Nice 👍

@garyb garyb merged commit 8486918 into purescript:master Mar 25, 2016
@garyb
Copy link
Member

garyb commented Mar 25, 2016

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants