mirror of
https://github.com/ilyakooo0/Idris-dev.git
synced 2024-11-14 03:14:14 +03:00
be1569e66d
We weren't shadowing names correctly when a class was parameterised on a single variable and one of the methods bound the same name. This almost never happens, but leads to very odd error messages when it does. Fixes #2026
13 lines
227 B
Idris
13 lines
227 B
Idris
|
|
class MyFunctor (f : Type -> Type) where
|
|
mymap : (m : a -> b) -> f a -> f b
|
|
|
|
data Foo x y = Bar y
|
|
|
|
instance MyFunctor (Foo m) where
|
|
mymap m x = ?wibble
|
|
|
|
instance [foo] Functor m => MyFunctor m where
|
|
mymap m x = map m x
|
|
|