On Wed, Sep 29, 2010 at 9:13 PM, Alexander Solla wrote:
> On 09/29/2010 02:15 PM, DavidA wrote:
>>>
>>> instance Monad (\v -> Vect k (Monomial v))
>>> >
>>
>> Yes, that is exactly what I am trying to say. And since I'm not allowed to
>> say
>> it like that, I was trying to say it using a type sy
David,
Ryan Ingram wrote:
>>> Haskell doesn't have true type functions; what you are really saying
>>> is
>>>
>>> instance Monad (\v -> Vect k (Monomial v))
Daniel Fischer wrote:
> I think there was a theoretical reason why that isn't allowed (making type
> inference undecidable? I don't reme
On 09/29/2010 09:13 PM, Alexander Solla wrote:
On 09/29/2010 02:15 PM, DavidA wrote:
instance Monad (\v -> Vect k (Monomial v))
>
Yes, that is exactly what I am trying to say. And since I'm not
allowed to say
it like that, I was trying to say it using a type synonym
parameterised over v
i
On 09/29/2010 02:15 PM, DavidA wrote:
instance Monad (\v -> Vect k (Monomial v))
>
Yes, that is exactly what I am trying to say. And since I'm not allowed to say
it like that, I was trying to say it using a type synonym parameterised over v
instead.
Why not:
instance Monad ((->) Vect k (M
On Wed, Sep 29, 2010 at 11:15 PM, DavidA wrote:
> Ryan Ingram gmail.com> writes:
>
>> Haskell doesn't have true type functions; what you are really saying is
>>
>> instance Monad (\v -> Vect k (Monomial v))
>>
>
> Yes, that is exactly what I am trying to say. And since I'm not allowed to say
> it
It's hard. Here's a simple example:
type Foo f = f Int
class C (f :: (* -> *) -> *) where
thingy :: f [] -> f IO
-- Should this ever typecheck? I would say no; there's no way to
unify f [] with [Int].
callThingy :: [Int] -> IO Int
callThingy = thingy
-- but what if you say this?
instance C
On Wednesday 29 September 2010 23:15:14, DavidA wrote:
> Ryan Ingram gmail.com> writes:
> > Haskell doesn't have true type functions; what you are really saying
> > is
> >
> > instance Monad (\v -> Vect k (Monomial v))
>
> Yes, that is exactly what I am trying to say. And since I'm not allowed
> t
Ryan Ingram gmail.com> writes:
> Haskell doesn't have true type functions; what you are really saying is
>
> instance Monad (\v -> Vect k (Monomial v))
>
Yes, that is exactly what I am trying to say. And since I'm not allowed to say
it like that, I was trying to say it using a type synonym par