Add filestat() documentation.

Rebased and edited version of #145