git.iko.soy/rowtype-yoga/purescript-native
on golang help sign in
Update type classes docs
31bc89ePhil Freeman
README.md+4
@@ -849,6 +849,10 @@ foreign import member "length" length :: forall a. [a] -> Number
849
849
850PureScript has basic support for type classes via the `class` and `instance` keywords.
850PureScript has basic support for type classes via the `class` and `instance` keywords.
851
851
852+Type class instances must be of the form `String`, `Number`, `Boolean`, `[t]` or `C t1 ... tn`, and only a single type class parameter is supported.
853+
854+Type class instances are resolved based on the order in which they appeared in the source files. In particular, overlapping instances are permitted.
855+
852```haskell
856```haskell
853class Show a where
857class Show a where
854 show :: a -> String
858 show :: a -> String