(1)
Haskell requires type names to start with an uppercase letter, and variable names must start with a lowercase letter.
举例如下:
> let C = "foo"
<interactive>:20:5: Not in scope: data constructor ‘C’
> let c = "foo"
> c
"foo"
> :type c
c :: [Char]
(2)
The combination of :: and the type after it is called a type signature.
举例如下:
> :type 'a'
'a' :: Char
:: Char
就被称之为type signature
。