Non type-variable argument

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Non type-variable argument

Nikolay Kurtov
Hello everyone,

Please help me compile the program without the -XFlexibleContexts extension.
I don't understand the "Non type-variable argument" error message and googling does not shed any light on the problem.
Any help is appreciated.

% ghc --version
The Glorious Glasgow Haskell Compilation System, version 7.10.3

% ghc orfest.hs
orfest.hs:6:1:
    Non type-variable argument
      in the constraint: AM.MArray a (t, t, t, [i]) m
    (Use FlexibleContexts to permit this)
    When checking that ‘go’ has the inferred type
      go :: forall (m :: * -> *) t t1 t2 t3 (a :: * -> * -> *) i.
            (Read t, AM.Ix i, AM.MArray a (t, t1, t2, [i]) m) =>
            a i (t, t1, t2, [i]) -> [[Char]] -> t3 -> i -> m (t3, i)

This works:
% ghc orfest.hs -XFlexibleContexts

Regards,
Orfest

_______________________________________________
Beginners mailing list
[hidden email]
http://mail.haskell.org/cgi-bin/mailman/listinfo/beginners

orfest.hs (1K) Download Attachment
Loading...