July 2023
Intermediate to advanced
670 pages
17h 13m
English
As you’re writing Haskell and working with types, there are two ghci commands that will be immensely helpful to you. The :type command, which we often abbreviate :t, will give you the type of an arbitrary Haskell expression, and the :info command, which is often abbreviated :i, will give you a bit more information, but not for an arbitrary expression. :info will only work for functions that you’ve loaded in from a module or source file. Let’s look at a few examples of using :type to get the type information from some expressions. You won’t understand many of the types here yet, but as you work your way through the chapter, you’ll get a chance to use all of the features individually, and by the end, you’ll be able ...