Text.Pandoc.Pretty: Improve performance of realLength

Eliminates memory usage and twofold increase in speed.
Merge pull request #1790 from mpickering/master

Text.Pandoc.Pretty: Improve performance of realLength