Created
          July 18, 2014 03:39 
        
      - 
      
- 
        Save bicycle1885/c4553dda851e4999d4c4 to your computer and use it in GitHub Desktop. 
    deduction error
  
        
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | {-# LANGUAGE FlexibleContexts #-} | |
| import qualified Data.Vector.Generic as G | |
| fooG :: (G.Vector v Int) => Int -> v Int -> v Bool | |
| fooG x = G.map (> x) | |
| -- hello.hs:5:10:Could not deduce (G.Vector v Bool) arising from a use of ‘G.map’ | |
| -- from the context (G.Vector v Int) | |
| -- bound by the type signature for | |
| -- fooG :: G.Vector v Int => Int -> v Int -> v Bool | |
| -- at hello.hs:4:9-50 | |
| -- In the expression: G.map (> x) | |
| -- In an equation for ‘fooG’: fooG x = G.map (> x) | 
  
    Sign up for free
    to join this conversation on GitHub.
    Already have an account?
    Sign in to comment
  
            
{-# LANGUAGE FlexibleContexts #-} import qualified Data.Vector.Generic as G fooG :: (G.Vector v Bool, G.Vector v Int) => Int -> v Int -> v Bool fooG x = G.map (> x)