Ooops. I completely forgot to show you the implementation of read. Silly of me. It's application: - fun read (r : 'a reader) s = r s;