Skip to content

Commit

Permalink
typo: Replaced return with pure (#82)
Browse files Browse the repository at this point in the history
  • Loading branch information
kika authored and paf31 committed Jun 21, 2017
1 parent 2fb18e9 commit 0ce240b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion guides/Generic.md
Expand Up @@ -78,7 +78,7 @@ instance decodePerson :: Decode Person where
decode value = do
name <- value ! "name"
location <- value ! "location"
return $ Person { name, location }
pure $ Person { name, location }
```

This is not too bad, but real-world records often contain many more fields. Also, it would be nice if we could be sure that the corresponding _encoding_ function would always generate compatible data. Let's see how to verify the same data using `Generic`, which will solve both of these problems.
Expand Down

0 comments on commit 0ce240b

Please sign in to comment.