understanding the type signature of (.)

Viewed 191

I'm just learning Haskell and functional programming using Richard Bird's book and came across the type signature of the (.) function. Namely

(.) :: (b -> c) -> (a -> b) -> (a -> c)

and the associated definition

(f . g) x = f (g x)

I understand what the operator is doing but am a bit confused about how to read the type signature. Is it saying that (.) takes as its first argument a function of type (b -> c), then returns a function of type (a -> b), and finally returns a function of type (a -> c)? Is this the right way to read the type signature?

Also, could this be an example of currying, where (.) is a curried function that takes two parameters? Or is that not the correct way to think about currying?

2 Answers
Related