Skip to content

Commit

Permalink
Update TypeErrors.md
Browse files Browse the repository at this point in the history
  • Loading branch information
hanshoglund committed May 6, 2014
1 parent 040f2a8 commit 1743b14
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions src/TypeErrors.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,9 @@ Utility functions `asScore` etc
The `lens` library is famously huge. The concepts you need to use Music Suite are
`Lens`, `Prism`, `Iso` and `Traversal`.

If you get an error on the form
The most common error in code that uses lenses is mixing up a lenses with functions, i.e. writing `duration` when you mean `view duration`. This will give you an error that looks something like this:

Couldn't match expected type `Time' with actual type `a0 -> f0 a0'

you probably mixed up a lens or getter with an acessor (i.e. `duration` vs `view duration`).
Couldn't match expected type `Duration' with actual type `a0 -> f0 a0'

### Get an intuition for what the classes and type functions do

Expand Down

0 comments on commit 1743b14

Please sign in to comment.