begin Vo Minh Thu quotation: > I guess it is short because you make use of second... so you can > define second' for your B data type, or make B an instance of Arrow.
I don't think that's the case. The code for "f" is making use of the Arrow instance for (->): second :: Arrow a => a b c -> a (d, b) (d, c) (str ++) :: [Char] -> [Char] second (str ++) :: (d, [Char]) -> (d, [Char]) All the caller can control here is what sort of "d" is passed through unchanged, not the fact that the resulting function expects a pair and returns a pair. -md _______________________________________________ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe