Effective Haskell: Regarding OverloadedStrings and FlexibleInstances (ch. 9, p. 279, pdf, B 2.0)

It may be too much nitpicking, but you could consider describing the context in which the two language extensions (OverloadedStrings and FlexibleInstances) are relevant.

If the implementation of our List type is in a file, the “FlexibleInstances” language extension is needed in that file in order to implement an instance of the IsString class.

If testing happens in “ghci”, then the “OverloadedStrings” language extension is needed there, at the time of using the overloading feature.

1 Like

Good note, I’ll take a look at revising that- thanks!