def map(self, fn: Callable[[Any], Any]) -> 'Reader':
        r"""Map a function over the Reader.

        Haskell:
        fmap f m = Reader $ \r -> f (runReader m r).
        fmap f g = (\x -> f (g x))
        """
        def _compose(x: Any) -> Any:
            try:
                ret = fn(self.run(x))
            except TypeError:
                ret = partial(fn, self.run(x))
            return ret
        return Reader(_compose)