Fixing compile problems with some versions of libc++.

Reported by Craig Leres.