|
|
От: |
Lexey
|
|
| Дата: | 15.02.17 10:24 | ||
| Оценка: | |||
S>>Это по ссылке выше, если что.S>>You can recognise the presence of ad-hoc polymorphism by looking for constrained type variables: that is, variables that appear to the left of =>, like in elem :: (Eq a) => a -> [a] -> Bool. Note that lookup :: (Eq a) => a -> [(a,b)] -> Maybe b exhibits both parametric (in b) and ad-hoc (in a) polymorphism.