make it work on OSX, but not in GHCI :(