std.file: Fix race condition when mkdirRecurse runs concurrently

mkdirRecurse would crash if a directory was created between its
exists() and mkdir() calls. This could occur if mkdirRecurse was called
at the same time from mutiple threads or processes.

Instead of relying on the exists() check to indicate whether the next
mkdir() should succeed, we explicitly ignore "already exists" errors
from the OS. Note that this changes the behavior of mkdirRecurse when
the leaf directory already existed: previously it would throw, whereas
now it will silently succeed. The new behavior is conformant with some
other implementations of "recursive mkdir": the -p flag of the GNU
tool, Ruby's mkpath, Java's mkdirs, and Perl's make_path. (On the
other hand, the old behavior was equivalent to the behavior of
Python's makedirs).
std.file: Simplify/optimize mkdirRecurse

The left.length != pathname.length check both takes care of the
Windows-only check, and it avoids a pointless stat on the FS root.